n'Abend, ich sitze gerade am Centerblock der Bamagalerie an der Datei (new_images_center.php) und grüble, wie ich die Vorschaubilder in der Größe ändern kann (Breite wie Höhe). Die sind mir im Moment etwas zu groß. Der Block an der Seite wird ja über die Thumbnailsbreite im Adminmenü gesteuert. Der Centerblock reagiert da aber leider nicht darauf.
...und obwohl ich im Adminmenü gewählt habe dass kein blank.gif davor sein soll, sind die Bilder bei diesem Block trotzdem dahinter. Dass wäre mir aber nicht so wichtig. Wichtig ist die Größe!!
Kann mir da mal jemand nen Tipp geben?
Danke Gargi
PHP Code:1: <?php 2: 3: /** 4: $Id: new_images_center.php, V 3.4 - 2005/03/18 10:03:12 bama Exp $ 5: eXV2 Content Management System 6: Link: http://www.exv2.de 7: Original Author: Hans Marx (bama) 8: Author Website : http://www.bama-webdesign.de 9: License by Hans Marx 10: License for eXV2 11: */ 12: function b_new_images_center_show($options) { 13: global $db, $xoopsConfig, $myts; 14: if ( !defined("BAMAGALERIE3_ACCESS") ) {define("BAMAGALERIE3_ACCESS", 1);} 15: include_once(XOOPS_ROOT_PATH."/modules/bamagalerie3/include/config.php"); 16: inc_class_form("class", "BAMAGAL_IMG_INCLUDED", "bama_img.php", "bamagalerie3"); 17: $block = array(); 18: $block['title'] = _MB_BG_NEWS_CT; 19: $block['content'] = ""; 20: $parm_arr = array("bama_imgfree"); 21: $xoopsConfig = ExV2_Config::getExV2_Configuration_Key_Value($parm_arr); 22: 23: if ( $xoopsConfig['bama_imgfree']==1 ){$ing_conf="free>=1";}else{$ing_conf="free=1";} 24: $ges = isset($options[0]) ? $options[0] : 5; 25: $titre_on = isset($options[1]) ? $options[1] : 1; 26: $anz = 0;$anz_ges=0; 27: $tb_w = isset($options[2]) ? $options[2] : 5; 28: $new_list = BamaImg::getAllImg(array($ing_conf), true, "date desc", $ges, 0); 29: if( count($new_list) > 0 ){ 30: $block['content'] .="<br><table width='100%' cellspacing='0' cellpadding='5' border='0'><tr>"; 31: foreach ( $new_list as $img_Dat ) { 32: $titre = $myts->makeTboxData4Show($img_Dat->titre()); 33: $block['content'] .="<td align='center' valign='top'>"; 34: $titre = isset($titre) && $titre != "" ? $titre : str_replace(array(".jpg",".jpeg",".gif",".png",".wbmp",".JPG",".JPEG",".GIF",".PNG",".WBMP"), array("","","","","","","","","",""), $myts->makeTboxData4Show($img_Dat->img())); 35: 36: $size = @getimagesize(BAMAGALERIE3_PATH."/thumbnails/".$img_Dat->img()); 37: 38: $block['content'] .= "<table border='0' cellspacing='0' cellpadding='0'><tr><td align='center'>"; 39: 40: $block['content'] .= "<table border='0' cellspacing='0' cellpadding='0'>"; 41: $block['content'] .= "<tr><td style='background-image:url(".BAMAGALERIE3_URL."/thumbnails/".$img_Dat->img().")'>"; 42: $block['content'] .= "<a href='".BAMAGALERIE3_URL."/viewcat.php?id=".$img_Dat->id()."&cid=".$img_Dat->cid() ."&min=0&orderby=titreA&show=".(isset($show) ? $show : "")."'><img src='".XOOPS_URL."/modules/bamagalerie3/images/blank.gif' ".$size[3]." border='0' alt='".$titre."'></a>"; 43: $block['content'] .= "</td></tr></table>"; 44: 45: 46: $block['content'] .= "</td></tr>"; 47: if( $titre_on == 1 ){ 48: $block['content'] .= "<tr><td align='center'>".$titre; 49: $block['content'] .= "</td></tr>"; 50: } 51: $block['content'] .= "</table>"; 52: 53: 54: 55: $block['content'] .= "</td>"; 56: $anz++; 57: $anz_ges++; 58: if( $anz == $tb_w && $anz_ges < $ges){ 59: $block['content'] .= "</tr><tr>"; 60: $anz = 0; 61: } 62: } 63: if( $anz < $tb_w){ 64: for($x=0; $x < ($tb_w-$anz); $x++){ 65: $block['content'] .= "<td> </td>"; 66: } 67: } 68: 69: $block['content'] .= "</tr></table><br>"; 70: return $block; 71: }else{ 72: return false; 73: } 74: } 75: 76: function b_new_images_center_edit($options) { 77: inc_class_form("form", "EXOOPS_FORM_PRODUCER_INCLUDED", "exoops_form_producer.php"); 78: $form = "<table border='0' cellpadding='2' cellspacing='0'>"; 79: $temp = ExoopsFormProducer::f_select("", "options[0]", (isset($options[0]) ? $options[0] : 5), 1, inc_function("arr_1_bis_30")); 80: $form .= "<tr><td align='right'>"._BG_NEWS_LIMIT."</td><td>".$temp->render()."</td></tr>"; 81: $temp = ExoopsFormProducer::f_radio_yn("", "options[1]", (isset($options[1]) ? $options[1] : 1), _YES, _NO); 82: $form .= "<tr><td align='right'>"._MB_BG_NAME."</td><td>".$temp->render()."</td></tr>"; 83: $temp = ExoopsFormProducer::f_select("", "options[2]", (isset($options[2]) ? $options[2] : 5), 1, inc_function("arr_dezimal", array(1,5,1))); 84: $form .= "<tr><td align='right'>"._BG_NEWS_WIDTH."</td><td>".$temp->render()."</td></tr>"; 85: $form .= "</table>"; 86: return $form; 87: } 88: 89: ?>
Bitte PHP Code immer mit dem Button PHP Code einbinden.
[ Geändert von Nobse am 28.01.2009 20:32 ] |