}) </script> </head> <body> <div class="title"></div> <div class="main_body"> <div class="conbox"> <?php $sql = "select * from `th_rec` limit 0,4"; $query = $db->query($sql); while ($row = $db->fetch_array($query)) { $pic = ''; if ($row['pic']) { $pic = getPicUrl($row['pic']); } ?> <form enctype="multipart/form-data" method="post"> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="20%" height="25" align="right" class="left"><?php echo $row['title']; ?> :</td> <td align="left"><?php if ($pic) { ?> <img src="<?php echo HOST . $pic; ?>
?> ><img src="images/spacer.gif" border="0" alt="" width="1" height="10"><br> <?php if (!empty($pro['pic'][$i * 4])) { ?> <table cellpadding="0" cellspacing="0" border="0" class="wrapper_box"> <tbody><tr><td class="pic2_padd"> <table cellpadding="0" cellspacing="0" border="0" align="center" class="wrapper_pic_table"> <tbody><tr><td class="wrapper_pic_td"><?php if (!empty($pro['pic'][$i * 4])) { ?> <a href="detial.php?id=<?php echo $pro['id'][$i * 4]; ?> "><img src="<?php echo HOST . getPicUrl($pro['pic'][$i * 4]); ?> " border="0" alt="<?php echo $pro['name'][$i * 4]; ?> " title="<?php echo $pro['name'][$i * 4]; ?> " width="210" height="215"></a><?php } ?> </td></tr> </tbody></table></td></tr> <tr><td <?php if (!empty($pro['name'][$i * 4])) { ?>
echo $row['title']; ?> " /> English: <input type="text" name="entitle" id="entitle" value="<?php echo $row['entitle']; ?> " /></td> </tr> <tr> <td class="left">Picture:</td> <td><?php if ($row['pic']) { ?> <img src="<?php echo HOST . getPicUrl($row['pic']); ?> " width="150" /><br /> <?php } else { echo '未上傳圖片<br><br>'; } ?> <input type="file" name="pic" id="pic" /> <input type="hidden" name="oldpic" id="oldpic" value="<?php echo $row['pic']; ?> " /></td> </tr> <tr> <td class="left"><label for="author">作者:</label></td>
$name = $row['name']; $enname = $row['enname']; $oord = $row['ord']; $url = $row['url']; $intro = $row['intro']; $enintro = $row['enintro']; $path = $row['path']; $vname = $row['vname']; $envname = $row['envname']; $vlink = $row['vlink']; $envlink = $row['envlink']; if ($spicid = $row['spic']) { $spicurl = getPicUrl($spicid); } if ($bpicid = $row['bpic']) { $bpicurl = getPicUrl($bpicid); } $ordsql = "select ord from `th_pro_class` where fid=" . $fid . " order by cast(ord as char)"; $ordlist = '<select name="ord">'; $ordquery = $db->query($ordsql); $cou = 0; while ($ordrow = $db->fetch_array($ordquery)) { $sel = ''; $cou += 1; if ($oord == $ordrow['ord']) { $sel = 'selected="selected"'; } $ordlist .= '<option ' . $sel . ' value="' . $ordrow['ord'] . '">' . $cou . '</option>'; } $ordlist .= '</select>'; $dis = $row['dis'];
$sql = "select id,name,ord,pic from `th_sr_content` order by ord desc limit {$firstEditCount},{$eachDisEditNums}"; $query = $db->query($sql); $pcount = 0; while ($row = $db->fetch_array($query)) { $pros['id'][$pcount] = $row['id']; $pros['name'][$pcount] = $row['name']; $pros['dis'][$pcount] = $row['dis']; if (empty($row['pic'])) { $pros['picurl'][$pcount] = ''; } else { $pics = rtrim($row['pic'], ','); $pics = explode(',', $pics); sort($pics); //重新Sequence $pic = $pics[0]; $pros['picurl'][$pcount] = getPicUrl($pic); //取得第一个圖片的url } $pcount++; } } if ($getAction == 'del_pro') { $id = $_GET['id']; if ($id) { $db->delete('th_sr_content', 'id=' . $id); header("location:prolist.php?act=pro_list&suc=del_suc"); exit; } else { header("location:prolist.php?act=pro_list&suc=del_fal"); } }
?> </div> </div> <div class="cl_both"></div> <div class="rls"> <ul style="list-style-type: none; }"> <?php $sql = "select id,name,pic from `th_pro_content` where cid={$cid} and id<>{$id}"; $query = $db->query($sql); while ($row = $db->fetch_array($query)) { $pics = rtrim($row['pic'], ','); $pics = explode(',', $pics); sort($pics); $pic = $pics[0]; if (!empty($pic)) { $pic = getPicUrl($pic); } ?> <li style="text-align:left;"><a href="detial.php?id=<?php echo $row['id']; ?> "><img src="<?php echo HOST . $pic; ?> " alt="<?php echo $name; ?> "></a><h3><?php echo $row['name']; ?> </h3></li>
</div> </div> <div class="box-bd"> <div class="goods-list-section"> <div class="xm-goods-list-wrap xm-goods-list-wrap-col20"> <ul class="xm-goods-list clearfix"> <?php if (is_array($searchGoods["list"])) { foreach ($searchGoods["list"] as $key => $v) { ?> <li > <div class="xm-goods-item"> <div class="item-thumb"> <a href=""> <img src="<?php echo getPicUrl($v['img']); ?> " alt="<?php echo $v["name"]; ?> " /> </a> </div> <div class="item-info"> <h3 class="item-title"> <a href=""><?php echo $v["name"]; ?> </a> </h3> <div class="item-price">
$proarray['name'][$pcount] = $prow['name']; $proarray['model'][$pcount] = $prow['model']; $proarray['pic'][$pcount] = $prow['pic']; $proarray['ford'][$pcount] = $prow['ford']; $proarray['hot'][$pcount] = $prow['hot']; $proarray['new'][$pcount] = $prow['new']; $proarray['dis'][$pcount] = $prow['dis']; if (empty($prow['pic'])) { $proarray['picurl'][$pcount] = ''; } else { $pics = rtrim($prow['pic'], ','); $pics = explode(',', $pics); sort($pics); //重新Sequence $pic = $pics[0]; $proarray['picurl'][$pcount] = getPicUrl($pic); //取得第一个圖片的url } $fsql = "select name from `th_pro_class` where ord=" . $prow['ford']; $fquery = $db->query($fsql); $frow = $db->fetch_array($fquery); $varpath = ''; if ($frow['name']) { $varpath .= $frow['name'] . '<br>↓<br>'; } $varpath .= $prow['subname']; $proarray['varpath'][$pcount] = $varpath; $pcount++; } /*$scount=0; $subarray['id'][$scount]=$proarray['subid'][0];