?? b_offerlist.php
字號:
function doSubmit() {
var str = trim(document.search.keywords.value);
if (str == "" ){
alert("請輸入關鍵字!");
return false;
} else {
if(document.search.postTime.value==0){
document.search.action ="http://page.alibaba.com.cn/buyer/turbine/template/buyer%2COfferSearch?keywords="+str;
}
document.search.submit();
}
}
function trim(inputString) {
if (typeof inputString != "string") { return inputString; }
var retValue = inputString;
var ch = retValue.substring(0, 1);
while (ch == " ") {
//檢查字符串開始部分的空格
retValue = retValue.substring(1, retValue.length);
ch = retValue.substring(0, 1);
}
ch = retValue.substring(retValue.length-1, retValue.length);
while (ch == " ") {
//檢查字符串結束部分的空格
retValue = retValue.substring(0, retValue.length-1);
ch = retValue.substring(retValue.length-1, retValue.length);
}
while (retValue.indexOf(" ") != -1) {
//將文字中間多個相連的空格變為一個空格
retValue = retValue.substring(0, retValue.indexOf(" ")) + retValue.substring(retValue.indexOf(" ")+1, retValue.length);
}
return retValue;
}
//-->
</SCRIPT>
<BR>
<!--section 2-->
<TABLE
style="BORDER-RIGHT: #c2c2c2 1px solid; BORDER-TOP: #c2c2c2 1px solid; BORDER-LEFT: #c2c2c2 1px solid; BORDER-BOTTOM: #c2c2c2 1px solid"
cellSpacing=0 cellPadding=2 width=750 bgColor=#efefef border=0>
<TBODY>
<TR>
<TD height=30 width="153">供應信息 </TD>
<TD align=right width="589">顯示:<a href=info.php>所有供求信息</a> <a href=seller.php>求購信息</a></TD>
</TR>
</TBODY>
</TABLE>
<!--section 3-->
<TABLE cellSpacing=0 cellPadding=0 width=750 border=0>
<TBODY>
<TR>
<TD><!-- loop -->
<?
// $catid=$catalog_id;
if ($start_page == NULL)
$start_page = 1;
$records_p = 20;
$infotype=1;
$tablename = "info";
$products_info = list_info6($rc,$tablename,$start_page,$records_p,$catalog_id,$infotype);
for ($i=0; $i < sizeof($products_info); $i++)
{
if ($products_info[$i]["img"] <> "")
$img = "(圖)";
else
$img = "";
$tempdate = $products_info[$i]["uptime"];
$todate = substr($tempdate,0,4)."年".substr($tempdate,4,2)."月".substr($tempdate,6,2);
$content=$products_info[$i]["content"];
if(strlen($content)>160)
$content=substr($content,0,158)."...";
$userid = $products_info[$i]["userid"];
$user_info = read_userid($rc, $userid);
$province= $user_info[0]["province"];
$city = $user_info[0]["city"];
$addr=$province.$city;
$company=$user_info[0]["company"];
?>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD style="PADDING-LEFT: 15px" width=619 bgColor=#ffffff
rowSpan=2><IMG height=4 src="../images/shim.gif" width=1><BR><BR>
<TABLE cellSpacing=0 cellPadding=0 width="98%" border=0>
<TBODY>
<TR>
<TD class=C vAlign=top align=left><A class=L
href="feedback.php?infoid=<? echo $products_info[$i]["infoid"]; ?>"
target=_blank><B><? echo $products_info[$i]["title"]; ?></b><? echo $img; ?></A> <FONT class=s
color=#666666><? echo $todate; ?></FONT><BR><IMG height=3
src="../images/shim.gif" width=1><BR><FONT class=C
color=#009999>[<? echo $addr ?>]</FONT> <A
href=""
target=_blank><? echo $company ?></A> <BR>
<BR><? echo $content ?>
<NOBR><A
href="feedback.php?infoid=<? echo $products_info[$i]["infoid"]; ?>"
target=_blank>詳細信息</A> <IMG height=15
src="../images/shim.gif" width=1> <BR><IMG height=9
src="../images/point_cat.gif" width=11 align=absMiddle>所在類別:
<? echo $catalog ?></A>
<SMALL>></SMALL>
<? echo $parent ?></A>
</NOBR></TD></TR></TBODY></TABLE><BR></TD>
<TD width=1 rowSpan=2><IMG height=1 src="../img/shim.gif"
width=1> </TD></TR>
<TR></TR></TBODY></TABLE>
<?
}
?>
<!-- end loop --></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=1 width=750 bgColor=#fcdfb4 border=0>
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#fef8e2
border=0><TBODY>
<TR>
<TD class=M noWrap align=middle>
<?
$total_records = total_info6($rc,$tablename,$catalog_id,$infotype);
if ($total_records%$records_p == 0)
$pages = $total_records/$records_p;
else
$pages = ($total_records-($total_records%$records_p))/$records_p + 1;
if ($start_page > 1){
?>
<a href="b_offerlist.php?catalog_id=<? echo $catalog_id ?>&catalog=<? echo $catalog ?>&parent=<? echo $parent ?>&start_page=<? echo $start_page-1 ?>"><img src="http://img.china.alibaba.com/images/seller/more03.gif" width="11" height="10" border="0" align="absmiddle">上一頁</a>
<?
}
if($pages>1){
$end_page=$pages-5;
if($start_page<=5)
$i_start=1;
else
$i_start=$start_page-5;
if($start_page<6){
if($pages<10)
$i_end=$pages;
else
$i_end=10;
}
else{
if($start_page<$end_page)
$i_end=$start_page+5;
else
$i_end=$pages;
}
for ($i=$i_start;$i<=$i_end;$i++) {
print "<b><a href=$filename?catalog_id=$catalog_id&catalog=$catalog&parent=$parent&start_page=$i>$i</a></b> ";
print " ";
}
}
if ($start_page < $pages){
?>
<a href="b_offerlist.php?catalog_id=<? echo $catalog_id ?>&catalog=<? echo $catalog ?>&parent=<? echo $parent ?>&start_page=<? echo $start_page+1 ?>">下一頁<img src="http://img.china.alibaba.com/images/seller/more02.gif" width="11" height="10" border="0" align="absmiddle"></a>
<?
}
$list_start=($start_page-1)*20+1;
$list_end=$list_start+19;
?>
</td>
</tr>
<tr>
<td align=center nowrap class="C">
共 <? echo $total_records; ?> 條供應信息,共 <? echo $pages ?> 頁,當前顯示為第 <? echo $start_page ?> 頁 第<? echo $list_start; ?> - <? echo $list_end; ?> 條信息
</td>
</tr>
</TBODY></TABLE></TD></TR></TBODY></TABLE><BR><BR><BR>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD bgColor=#dddddd><IMG height=2 src="../images/shim.gif"
width=2></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=10 width="100%" border=0>
<TBODY>
<TR>
<TD bgColor=#f1f1f1>
<table cellspacing=0 cellpadding=0 width=740 align=center border=0>
<tbody>
<tr>
<td class=LL align=center width="90%"><span
style="FONT-SIZE: 12px">版權所有:外貿無憂. Copyright ©1997-2003 www.ec51.com All
Rights Reserved.經營許可證編號:粵ICP證 <font color=red>030148</font><br>
服務電話:+86-755-26092307 傳真:+86-755-26099007 MSN:ec51@msn.com QQ:39759266
</span></td>
</tr>
</tbody>
</table>
<CENTER></CENTER>
<CENTER></CENTER></TR></TBODY></TABLE></CENTER></CENTER></BODY></HTML>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -