📄 view_product.php
字号:
$level= mysql_fetch_array($level_query);
echo $level["sb_levelname"];
?>
]</strong></font></font></strong></td>
</tr>
</table></td>
<td> <table width="100%" border="0" cellpadding="2" cellspacing="1">
<tr valign="top" class="onepxtable">
<td width="40%" height="25" class="subtitle"> <div align="left">Minimum
Order</div></td>
<td width="60%" height="25" class="innertablestyle" ><font class="normal"><?php echo $sbrow_off["sb_min_order"]; ?></font></td>
</tr>
<tr valign="top" class="onepxtable">
<td width="40%" height="25" class="subtitle"> <div align="left">Shipping
Cost</div></td>
<td width="60%" height="25" class="innertablestyle" ><font class="normal"><?php echo $sbrow_cur['sbcur_symbol'].' '.$sbrow_off["sb_shipping_cost"]; ?></font></td>
</tr>
<tr valign="top" class="onepxtable">
<td width="40%" height="25" class="subtitle"> <div align="left">Sample
Available</div></td>
<td width="60%" height="25" class="innertablestyle" ><font class="normal"><?php echo $sbrow_off["sb_samples_available"]; ?></font></td>
</tr>
<tr valign="top" class="onepxtable">
<td width="40%" height="25" class="subtitle"> <div align="left">Product
Status</div></td>
<td width="60%" height="25" class="innertablestyle" ><font class="normal"><?php echo $sbrow_off["sb_product_status"]; ?></font></td>
</tr>
</table></td>
</tr>
<tr valign="top">
<td colspan="2"><table width="100%" border="0" cellspacing="1" cellpadding="1">
<tr valign="top" class="onepxtable">
<td height="25" class="subtitle"> <div align="left">Payment
Mode</div></td>
<td height="25" class="innertablestyle" ><font class="normal">
<?php
$sb_payment_mode=$sbrow_off["sb_payment_mode"];
$sb_other_mode=$sbrow_off["sb_other_mode"];
if(strstr($sb_payment_mode,'cash'))
echo 'Cash<br>';
if(strstr($sb_payment_mode,'cheque'))
echo 'Cheque<br>';
if(strstr($sb_payment_mode,'credit'))
echo 'Credit Card<br>';
if(strstr($sb_payment_mode,'bank'))
echo 'Bank Transfer<br>';
if(strstr($sb_payment_mode,'loc'))
echo 'Letter of Credit<br>';
if(strstr($sb_payment_mode,'escrow'))
echo 'Escrow<br>';
echo $sb_other_mode;
//echo $sb_payment_mode;
// echo $sbrow_off["sb_description"]; ?>
</font></td>
</tr>
<tr valign="top" class="onepxtable">
<td width="20%" height="25" class="subtitle"> <div align="left">Categories</div></td>
<td height="25" class="innertablestyle">
<?php
$sbq_cat="select * from sbbleads_product_cats where sb_offer_id=$id";
//echo $sbq_cat;
$sbrs_cat=mysql_query($sbq_cat);
/* $sbcat_exists=false;
*/ while($sbrow_cat=mysql_fetch_array($sbrs_cat))
{
$catpath="";
$cat_query=mysql_query("Select * from sbbleads_categories where sb_id=".$sbrow_cat["sb_cid"] );
/* if($sbrow_cat["sb_cid"] == $cid) //working code
// continue; //for skipping the category that is alreday displayed or passed
*/ while ($rs=mysql_fetch_array($cat_query))
{
/* $sbcat_exists=true; //just checks whether we come in this portion ever
*/ $catpath =" > <a href=\"cat_products.php?cid=" . $rs["sb_id"] . "\">" .$rs["sb_cat_name"]."</a>".$catpath;
$cat_query=mysql_query("Select * from sbbleads_categories where sb_id=" . $rs["sb_pid"] );
}
echo '<a href="index.php">Home</a>'.$catpath.'<br>';
}
/* if(!$sbcat_exists)
echo $config["sb_null_char"]; //prints in case no other category than cid
*/ ?>
</td>
</tr>
</table></td>
</tr>
<tr valign="top">
<td colspan="2"><table width="100%" border="0" cellspacing="1" cellpadding="2" class="innertablestyle">
<tr valign="bottom">
<td align="center"><a href="contactuser.php?sb_type=3&sb_id=<?php echo $id; ?>"><img src="<?php echo $send_inquiry_icon;?>" border="0" alt="Send Inquiries" onMouseOver="javascript: window.status='Send inqueries to user'; return true;" onMouseOut="javascript: window.status=''; return true;" ></a></td><?php
$sbq_com="select * from sbbleads_companyprofiles where sb_uid=".$sbrow_off["sb_uid"];
$sbrow_com=mysql_fetch_array(mysql_query($sbq_com));
if($sbrow_com)
{
?><td align="center"> <a href="view_profile.php?id=<?php echo $sbrow_com["sb_id"]; ?>"><img src="<?php echo $company_profile_icon;?>" border="0" alt="View Company Profile" onMouseOver="javascript: window.status='View company profile'; return true;" onMouseOut="javascript: window.status=''; return true;" ></a></td><?php
} //end if sbrow_com ?>
<td align="center"><a href="addtocart.php?sb_type=3&sb_id=<?php echo $id; ?>"><img src="<?php echo $inquiry_basket_icon;?>" border="0" alt="Add to Inquiry Basket" onMouseOver="javascript: window.status='Add to inquiry basket'; return true;" onMouseOut="javascript: window.status=''; return true;" ></a></td>
<td align="center"> <a href="dummy.htm" onClick="return win('<?php echo "sb_type=1&sb_id=$id&username=".$mem["sb_username"]; ?>');" ><img src="<?php echo $contact_list_icon;?>" border="0" alt="Add to Contact List" onMouseOver="javascript: window.status='Add to contact list'; return true;" onMouseOut="javascript: window.status=''; return true;" ></a></td>
<td align="center"><a href="dummy.htm" onClick="return win1('<?php echo "sb_type=1&sb_id=$id&username=".$mem["sb_username"]; ?>');"><img src="<?php echo $block_list_icon;?>" border="0" alt="Add to Block List" onMouseOver="javascript: window.status='Add to block list'; return true;" onMouseOut="javascript: window.status=''; return true;" ></a></td>
<td align="center"> <a href="add_favorites.php?sb_type=3&sb_id=<?php echo $id; ?>"><img src="<?php echo $add_fav_icon;?>" border="0" alt="Add to Favorites" onMouseOver="javascript: window.status='Add to favorites'; return true;" onMouseOut="javascript: window.status=''; return true;" ></a></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
<tr>
<td valign="top"><table width="90%" border="0" align="center" cellpadding="0" cellspacing="0" class="onepxtable">
<tr>
<td class="titlestyle"> Relevant Images</td>
</tr>
</table>
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="1" class="seperatorstyle">
<?php
$sbq_img="select * from sbbleads_product_images where sb_offer_id=$id";
// die($sbq_img);
$sbrs_img=mysql_query($sbq_img);
if(mysql_num_rows($sbrs_img)>0)
{
$sbcnt=0;
$sbimg_per_row=4;
while($sbrow_img=mysql_fetch_array($sbrs_img))
{
?>
<?php if($sbcnt%$sbimg_per_row == 0)
{ ?>
<tr>
<?php
} //end if
$sbcnt++;
?>
<td height="100%" width="<? echo 100/$sbimg_per_row;?>%"> <table width="100%" height="100%" border="0" cellpadding="5" cellspacing="0" class="innertablestyle">
<tr>
<td><div align="center"><a href="uploadedimages/<?php echo $sbrow_img["sb_img_url"]; ?>" target="_blank"><img src="<?php echo $img_path;?><?php echo $sbrow_img["sb_img_url"]; ?>" border="0" <? echo $img_pmt; ?>></a></div></td>
</tr>
</table></td>
<?php if($sbcnt%$sbimg_per_row == 0)
{ ?>
</tr>
<?php
} //end if
} //end while
//////-------padding empty tds
$sb_remainder=$sbcnt%$sbimg_per_row;
$sb_no_of_pads=($sb_remainder!=0)?$sbimg_per_row-$sb_remainder:0;
for($sb_new_counter=1;$sb_new_counter<=$sb_no_of_pads;$sb_new_counter++)
{
?>
<td class="innertablestyle"><img src="images/spacer.gif" <? echo $img_pmt; ?> border="0"></td>
<?php
} //end for padding
}
else
{ ?>
<tr>
<td class="innertablestyle" height="25"><font class="normal"> No
images have been uploaded</font></td>
</tr>
<?php
} //end else no img defined?>
</table></td>
</tr>
<tr>
<td valign="top"><table width="90%" border="0" align="center" cellpadding="0" cellspacing="0" class="onepxtable">
<tr>
<td class="titlestyle"> Description</td>
</tr>
</table>
<table width="90%" border="0" align="center" cellpadding="4" cellspacing="1" class="onepxtable">
<tr>
<td height="25" valign="top" class="innertablestyle"><?php echo $sbrow_off["sb_description"]; ?></td>
</tr>
</table></td>
</tr>
</table>
<?
}// end main
include "template.php";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -