?? list.skin.php
字號:
<?
if (!defined("_GNUBOARD_")) exit; // 俺喊 其撈瘤 立辟 閡啊
// 霸矯魄 汲瀝
if (!$board[bo_10]) $board[bo_10]="100"; // 撈固瘤冠膠農(nóng)扁
// 力格撈 滴臨肺 釬矯登綽 版快 撈 內(nèi)靛甫 葷儈秦 焊技夸.
// <nobr style='display:block; overflow:hidden; width:000px;'>力格</nobr>
$max = $board[bo_10] - 5 ; // 撈固瘤狼 啊肺技肺(變率)狼 彌措摹.
$noIMG = $board_skin_path."/img/noimage.gif"; // URL
$resol = 80 ; // 積己登綽 芥匙老狼 JPG拘綿伏.(欺季飄%)
function smaller( $W, $H ) {
global $max, $thum_W, $thum_H ;
if ( $W > $H ) { //啊肺屈老 版快.
$thum_W = $max ;
$thum_H = ceil( $H * ( $max / $W ) );
}
if ( $W < $H ) { //技肺屈老 版快.
$thum_H = $max ;
$thum_W = ceil( $W * ( $max / $H ) );
}
if ( $W == $H ) { //瀝葷阿屈老 版快.
$thum_W = ceil( $max * 0.8 );
$thum_H = ceil( $max * 0.8 );
}
return $thum_W ;
return $thum_H ;
}
function maker( $thum_W, $thum_H ) {
global $thum, $resol, $ori, $ori_info ;
//$newImg = ImageCreate($thum_W,$thum_H); // GD扼撈宏礬府 2.0 (撈竅老 版快)
$newImg = ImageCreateTrueColor($thum_W,$thum_H); // GD扼撈宏礬府 2.0 傈儈竊薦
if($ori_info[2]=="2") $origImg=ImageCreateFromjpeg($ori);
if($ori_info[2]=="3") $origImg=ImageCreateFrompng($ori);
//ImageCopyResized($newImg,$origImg,0,0,0,0,$thum_W,$thum_H,ImageSX($origImg),ImageSY($origImg));
imageCopyResampled($newImg,$origImg,0,0,0,0,$thum_W,$thum_H,ImageSX($origImg),ImageSY($origImg));
Imagejpeg($newImg, $thum, $resol );
@chmod($thum,0707);
ImageDestroy($newImg);
ImageDestroy($origImg);
return $thum ;
}
##########################################
function showtextintags($text) {
$text = preg_replace("/(\<script)(.*?)(script>)/si", "dada", "$text");
$text = strip_tags($text);
$text = str_replace("<!--", "<!--", $text);
$text = preg_replace("/(\<)(.*?)(--\>)/mi", "".nl2br("\\2")."", $text);
return $text;
}
##########################################
// 急琶可記欄肺 牢秦 伎欽摹扁啊 啊函利欄肺 函竊
$colspan = 10;
if ($is_category) $colspan++;
if ($is_checkbox) $colspan++;
if ($is_good) $colspan++;
if ($is_nogood) $colspan++;
// 力格撈 滴臨肺 釬矯登綽 版快 撈 內(nèi)靛甫 葷儈秦 焊技夸.
// <nobr style='display:block; overflow:hidden; width:000px;'>力格</nobr>
?>
<style type="text/css">
<!--
.w_fixed { table-layout:fixed; }
.w_font { font-family:蹈框; font-size:9pt; color:#5E5E5E; }
.w_title { font-family:蹈框; font-size:9pt; color:#5E5E5E; }
.w_num { font-family:蹈框; font-size:9pt; color:#7BB2D6; }
.w_list { font-family:蹈框; font-size:9pt; color:#6A6A6A; }
.w_notice { font-family:蹈框; font-size:9pt; color:#2C88B9; }
.w_comment_cnt { font-family:蹈框; font-size:8pt; color:#9A9A9A; }
.w_padding { PADDING-LEFT: 15px; PADDING-BOTTOM: 5px; PADDING-TOP: 5px; }
.w_padding2 { PADDING-LEFT: 15px; PADDING-TOP: 5px; }
.w_text { BORDER: #D3D3D3 1px solid; HEIGHT: 18px; BACKGROUND-COLOR: #ffffff; }
.w_textarea { BORDER: #D3D3D3 1px solid; BACKGROUND-COLOR: #ffffff; WIDTH: 100%; WORD-BREAK: break-all; }
.w_message { font-family:蹈框; font-size:9pt; color:#4B4B4B; }
.w_norobot { font-family:蹈框; font-size:9pt; color:#BB4681; }
.title_han {color:FFFFFF;font-weight:bold;font-size:9pt}
.list_han {color:13485D;font-size:9pt;text-decoration:none;text-decoration:none}
.title_eng {font-family:tahoma;color:FFFFFF;font-weight:bold;font-size:8pt;text-decoration:none}
.list_eng {font-family:tahoma;color:13485D;font-size:8pt;text-decoration:none}
.head_01 {font-family:verdana;font-size:8pt;color:#555555}
.head_02 {font-family:verdana;font-size:8pt;color:#555555;font-weight:bold;text-decoration:underline}
-->
</style>
<!-- 惑竄 鷗撈撇 扼牢 何盒 -->
<table width="<?=$width?>" border="0" cellspacing="0" cellpadding="0" align=center>
<tr><td colspan=5 height="5" bgcolor='#<?=$board[bo_3]?>'></td></tr>
<tr>
<td width='15'></td>
<td width="3"><table width="1" height="35" cellpadding=0 cellspacing=0><tr><td bgcolor='#<?=$board[bo_3]?>' height="15"></td></tr><tr><td></td></tr></table></td>
<td width="100" align='center'><b>岸礬府 List</b></td>
<td width="3"><table width="1" height="35" cellpadding=0 cellspacing=0><tr><td bgcolor='#<?=$board[bo_3]?>' height="15"></td></tr><tr><td></td></tr></table></td>
<td></td>
<tr><td colspan=5 height="1" bgcolor="#ECECEC"></td></tr>
<tr><td colspan=5 height="1" bgcolor="#FFFFFF"></td></tr>
<tr><td colspan=5 height="1" bgcolor="#C4C4C4"></td></tr>
</tr>
</table>
<table width="<?=$width?>" align="center" cellpadding="0" cellspcing="0"><tr><td>
<!-- 盒幅 伎泛飄 冠膠, 霸矯拱 割扒, 包府磊拳擱 傅農(nóng) 矯累 -->
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<? if ($is_category) { ?><form name="fcategory" method="get">
<td width="50%"><select name=sca onchange="location='<?=$category_location?>'+this.value;"><option value=''>傈眉</option><?=$category_option?></select></td>
</form><? } ?>
<td height=25 align="right"><font class=w_font>霸矯拱 <?=number_format($total_count)?>扒</font><? if ($admin_href) { ?><a href="<?=$admin_href?>"><img src="<?=$board_skin_path?>/img/admin_button.gif" title="包府磊" width="63" height="22" border="0" align="absmiddle"></a><? } ?></td>
</tr>
</table>
<!-- 盒幅 伎泛飄 冠膠, 霸矯拱 割扒, 包府磊拳擱 傅農(nóng) 場 -->
<!-- 咯歸 --><table width="100%" cellspacing="0" cellpadding="0"><tr><td height="2"></td></tr></table>
<!-- 霸矯魄 力格 矯累 -->
<table width="100%" height=25 border=0 cellpadding=0 cellspacing=0 background="<?=$board_skin_path?>/img/board_t_bg.gif">
<form name="fboardlist" method="post">
<input type="hidden" name="bo_table" value="<?=$bo_table?>">
<input type="hidden" name="sfl" value="<?=$sfl?>">
<input type="hidden" name="stx" value="<?=$stx?>">
<input type="hidden" name="spt" value="<?=$spt?>">
<input type="hidden" name="page" value="<?=$page?>">
<input type="hidden" name="sw" value="">
<!-- 霸矯魄 力格 場 -->
<!-- 霸矯拱 府膠飄 矯累 -->
<? for ($i=0; $i<count($list); $i++) { ?>
<tr><td colspan="<?=$colspan?>" height="5" bgcolor=white></td></tr>
<tr height=28 class=list<?=($i%2)?> bgcolor='#FFFFFF'>
<td width="40" align="center" valign="middle">
<?
//if ($list[$i][is_notice]) // 傍瘤葷親
//echo "<img src=\"$board_skin_path/img/notice_icon.gif\" width=30 height=16>";
//else if ($wr_id == $list[$i][wr_id]) // 泅犁困摹
//echo "<font class=list_eng><strong>{$list[$i][num]}</strong></font>";
//else
//echo "<font class=list_eng>{$list[$i][num]}</font>";
?></td>
<? if ($is_checkbox) { ?><td width="40" align="center" valign="middle"><input type=checkbox name=chk_wr_id[] value="<?=$list[$i][wr_id]?>"></td> <? } ?>
<? // 撈固瘤 貿(mào)府何盒
##################################################################################################
$thum = "";
$list_view = "";
$image = urlencode($list[$i][file][0][file]); // 霉鍋擄 頗老撈 撈固瘤扼擱
$images = "$g4[path]/data/file/$bo_table/$image";
if (preg_match("/\.(gif|jpg|png)$/i", $image) && file_exists("$g4[path]/data/file/$bo_table/$image")) {
if (preg_match("/\.(gif|jpg|png)$/i", $image) && file_exists("$g4[path]/data/file/$bo_table/$image")) {
$ori = "$g4[path]/data/file/$bo_table/$image"; //[鞘薦](URL) "./img/Test.gif"
}
$ext = strtolower(substr(strrchr($ori,"."), 1)); //犬厘磊
if ( $ext=="gif"||$ext=="jpg"||$ext=="jpeg"||$ext=="png"||$ext=="bmp"||$ext=="tif"||$ext=="tiff")
$ori_info=getimagesize($ori);
else
$ori_info="";
//===== 盔頗老撈 [ 2JPG, 2JPEG, 3PNG ] 版快
if ( $ori_info[2]=="2" || $ori_info[2]=="3" ) {
$thum = $ori.".Thum" ;
if ( file_exists($thum) ) { // Thumbnail [O] 版快
$thum_info = getimagesize ($thum);
$thum_W = $thum_info[0] ;
$thum_H = $thum_info[1] ;
}
else { // Thumbnail [X] 版快
if ( smaller( $ori_info[0], $ori_info[1] ) ) {
maker( $thum_W, $thum_H );
}
}
}
//===== 盔頗老撈 [ 1GIF,6BMP,7TIF ] 版快
else if ( $ori_info[2]=="1" || $ori_info[2]=="6" || $ori_info[2]=="7" ) {
if ( smaller( $ori_info[0], $ori_info[1] ) ) { $thum = $ori ; }
}
//===== 盔頗老撈 [ 1,2,3,6,7 ] 酒匆 版快
else {
$thum = $noIMG ;
$noIMG_info = getimagesize ($noIMG);
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -