|
|
if ($CurrentCategory !="" or $C_ollectionVW !="" or $C_at!= "" or $Hot_Buys!=""){
echo "";
echo "";
echo "";
echo " | ";
echo " ";
}
///////////////////////////////
?>
|
if ($CurrentCategory !="" or $C_ollectionVW !="" or $Hot_Buys!="" or $C_at!="")
{
echo "";
echo "";
}else{
echo "";
}
$_SESSION['Furniture']=$CurrentCategory;
include("dbc.php");
$connection = mysql_connect("$host", "$username", "$password")or die("cannot connect");
mysql_select_db("$db_name")or die("cannot select DB");
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (CollectionYN = 'on') AND (OutletsiteYN= 'on') AND `furnituretype` ='" . $_SESSION['Furniture'] . "'";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++) {
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
};
if ($CurrentCategory !="" or $C_ollectionVW !="" or $Hot_Buys!="" or $C_at!="")
{
echo " | ";
echo " ";
}else{
echo "";
}
if ($Hot_Buys!="" and $C_at=="" and $CurrentCategory=="" and $C_ollectionVW==""){
echo "";
echo "";
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (`CastlehotbuysYN` = 'on') AND (OutletsiteYN= 'on') ";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++){
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
}
}
echo " | ";
echo " ";
if ($C_at!=""){
echo "";
echo "";
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (CollectionYN = 'on') AND (OutletsiteYN= 'on') ";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++) {
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
}
}
echo " | ";
echo " ";
include("dbc.php");
$connection = mysql_connect("$host", "$username", "$password")or die("cannot connect");
mysql_select_db("$db_name")or die("cannot select DB");
/////////////////////////////////////////////////////////////////////////////
if ($C_ollectionVW==""){
echo "";
}else{
if (isset($_GET["page"])) { $page = $_GET["page"]; } else { $page=1; };
$start_from = ($page-1) * 20;
$sql = "SELECT * FROM stage1dev WHERE (OutletsiteYN= 'on') AND `Collection` ='" . $C_ollectionVW . "' ORDER BY (positionBOT+0) ASC LIMIT $start_from, 21";
$rs_result = mysql_query ($sql,$connection);
$xa=0;
$ya=0;
echo"";
while ($row = mysql_fetch_array($rs_result)) {
$VendorID = $row['UID'];
$ItemSKU = $row['SKU'];
$Image = $row['ImageName'];
$vendorabbrev = $row['vendorabbreviation'];
$S1Cost = $row['OurPriceS1'];
$C_ollection = $row['Collection'];
$SuggestedRetail = $row['ListPriceS1'];
$ItemName = $row['ItemName'];
$ItemDescription = $row['saledesc'];
$WebOrder = $row['OrderS1'];
if ($xa == $ya){
echo"";
}
//echo "" . $xa . $ya. "";
$Image=str_replace(" ","%20",$Image);
echo"";
echo" " . $vendorabbrev . $ItemSKU . " ";
echo"";
echo" ";
echo" ";
echo"";
echo" ";
echo"$ " . $S1Cost . "";
echo"";
echo" ";
echo" ";
echo" ";
echo "Compare At ";
echo"";
$SuggestedRetail = number_format($SuggestedRetail);
echo"$" . $SuggestedRetail . "";
echo" ";
echo"" . $ItemName ;
echo " ";
echo "" . $ItemDescription;
echo" ";
echo"";
echo $VendorID . " - " . $WebOrder;
echo" ";
echo" | ";
if ($xa+3==$ya)
{
echo" ";
}
if ($xa == $ya){
$ya+=3;
}
$xa++;
}
echo" ";
}
///////////////////////////////////////////////////////////////////////////
if ($CurrentCategory==""){
echo "";
}else{
if (isset($_GET["page"])) { $page = $_GET["page"]; } else { $page=1; };
$start_from = ($page-1) * 20;
//$sql = "SELECT * FROM stage1dev WHERE (CollectionYN = 'on') AND (S1siteYN= 'on') AND `furnituretype` ='" . $_SESSION['Furniture'] . "' ORDER BY (OrderS1+0) ASC LIMIT $start_from, 21";
$sql = "SELECT * FROM stage1dev WHERE (OutletsiteYN = 'on') AND `furnituretype` ='" . $_SESSION['Furniture'] . "' ORDER BY (OrderS1+0) ASC LIMIT $start_from, 21";
$rs_result = mysql_query ($sql,$connection);
$x=0;
$y=0;
echo"";
while ($row = mysql_fetch_array($rs_result)) {
$VendorID = $row['UID'];
$ItemSKU = $row['SKU'];
$Image = $row['ImageName'];
$vendorabbrev = $row['vendorabbreviation'];
$S1Cost = $row['OurPriceS1'];
$C_ollection = $row['Collection'];
$SuggestedRetail = $row['ListPriceS1'];
$ItemName = $row['ItemName'];
$ItmDescription = $row['saledesc'];
$WebOrder = $row['OrderS1'];
if ($x == $y){
echo"";
}
$Image=str_replace(" ","%20",$Image);
echo"";
echo "" . $ItemDescription . "";
echo"";
echo"";
echo" ";
echo" ";
echo"";
echo" ";
echo"$ " . $S1Cost . "";
echo"";
echo" ";
echo" ";
echo" ";
echo "Compare At ";
echo"";
$SuggestedRetail = number_format($SuggestedRetail);
echo"$" . $SuggestedRetail . "";
echo" ";
echo"" . $ItemName;
echo " ";
echo "" . $ItmDescription . "Test";
echo" ";
echo"";
echo"";
echo $VendorID . " - " . $WebOrder;
echo" ";
echo" | ";
if ($x+3==$y)
{
echo" ";
}
if ($x == $y){
$y+=3;
}
$x++;
}
echo" ";
}
////////////////////////////////////////////////////////////////////////////
if ($CurrentCategory=="" and $C_ollectionVW=="" and $Hot_Buys=="" and $C_at==""){
echo "";
echo " ";
?>
}
/////////////////////////////////////////////////////////////////////
if ($C_at==""){
echo "";
}else{
if (isset($_GET["page"])) { $page = $_GET["page"]; } else { $page=1; };
$start_from = ($page-1) * 21;
$rotator=0;
$counter=0;
$x_bot=0;
$y_bot=0;
$startfrom=0 + $start_from;
echo"";
while($counter<=22){
//echo $startfrom . " ";
$CatalogueRotate=array("Sofas","Standard Dining","Bedroom","Coffee and End Tables","Sectionals","Patio");
$sql = "SELECT * FROM stage1dev WHERE (CollectionYN = 'on') AND (OutletsiteYN= 'on') AND`furnituretype` ='" . $CatalogueRotate[$rotator] . "' ORDER BY (OrderS1+0) ASC LIMIT $startfrom, 1";
$rs_result = mysql_query ($sql,$connection);
//echo $CatalogueRotate[$rotator] . " ";
while ($row = mysql_fetch_array($rs_result)) {
$VendorID = $row['UID'];
$ItemSKU = $row['SKU'];
$Image = $row['ImageName'];
$vendorabbrev = $row['vendorabbreviation'];
$S1Cost = $row['OurPriceS1'];
$C_ollection = $row['Collection'];
$SuggestedRetail = $row['ListPriceS1'];
$ItemName = $row['ItemName'];
$ItmDescription = $row['saledesc'];
$WebOrder = $row['OrderS1'];
if ($x_bot == $y_bot){
echo"";
}
$Image=str_replace(" ","%20",$Image);
echo"";
echo "" . $ItemDescription . "";
echo"";
echo"";
echo" ";
echo" ";
echo"";
echo" ";
echo"$ " . $S1Cost . "";
echo"";
echo" ";
echo" ";
echo" ";
echo "Compare At ";
echo"";
$SuggestedRetail = number_format($SuggestedRetail);
echo"$" . $SuggestedRetail . "";
echo" ";
echo"" . $ItemName;
echo " ";
echo "" . $ItmDescription . "Test";
echo" ";
echo"";
echo"";
echo $VendorID . " - " . $WebOrder;
echo" ";
echo" | ";
if ($x_bot+3==$y_bot)
{
echo" ";
}
if ($x_bot == $y_bot){
$y_bot+=3;
}
$x_bot++;
}
if ($rotator<=5){
$rotator++;
}else{
$rotator=0;
$startfrom+=6;
}
$counter++;
}
echo" ";
}
/////////////////////////////////////////////////////////////////////////////
if ($Hot_Buys!="" and $C_at=="" and $CurrentCategory=="" and $C_ollectionVW==""){
if (isset($_GET["page"])) { $page = $_GET["page"]; } else { $page=1; };
$start_from = ($page-1) * 20;
$sql = "SELECT * FROM stage1dev WHERE (`CastlehotbuysYN` = 'on') AND (OutletsiteYN= 'on') ORDER BY (OrderS1+0) ASC";
$rs_result = mysql_query ($sql,$connection);
$x=0;
$y=0;
echo"";
while ($row = mysql_fetch_array($rs_result)) {
$VendorID = $row['UID'];
$ItemSKU = $row['SKU'];
$Image = $row['ImageName'];
$vendorabbrev = $row['vendorabbreviation'];
$S1Cost = $row['OurPriceS1'];
$C_ollection = $row['Collection'];
$SuggestedRetail = $row['ListPriceS1'];
$ItemName = $row['ItemName'];
$ItemDescription = $row['saledesc'];
$WebOrder = $row['OrderS1'];
if ($x == $y){
echo"";
}
$Image=str_replace(" ","%20",$Image);
echo"";
echo"";
echo"";
echo"";
echo" ";
echo"$ " . $S1Cost . "";
echo"";
echo" ";
echo" ";
echo" ";
echo "Compare At ";
echo"";
$SuggestedRetail = number_format($SuggestedRetail);
echo"$" . $SuggestedRetail . "";
echo" ";
echo"" . $ItemName ;
echo " ";
echo "" . $ItemDescription;
echo" ";
echo"";
echo $VendorID . " - " . $WebOrder;
echo" ";
echo" | ";
if ($x+3==$y)
{
echo" ";
}
if ($x == $y){
$y+=3;
}
$x++;
}
echo" ";
}
?>
/////////////////////////////////////////////////////////////////////
if ($CurrentCategory!=""){
echo " | ";
echo "";
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (CollectionYN = 'on') AND (OutletsiteYN= 'on') AND `furnituretype` ='" . $_SESSION['Furniture'] . "'";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++) {
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
}
}
echo " | ";
echo " ";
?>
/////////////////////////////////////////////////////////////////////
if ($C_at!=""){
echo "";
echo "";
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (CollectionYN = 'on') ";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++) {
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
}
}
echo " | ";
echo " ";
?>
/////////////////////////////////////////////////////////////////////
if ($C_ollectionVW=="xyz"){
echo "";
echo "";
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (CollectionYN = 'on')";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++) {
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
}
}
echo " | ";
echo " ";
?>
/////////////////////////////////////////////////////////////////////
if ($Hot_Buys!="" and $C_at=="" and $CurrentCategory=="" and $C_ollectionVW==""){
echo "";
echo "";
$sql = "SELECT COUNT(*) FROM `stage1dev` WHERE (`CastlehotbuysYN` = 'on')";
$rs_result = mysql_query($sql,$connection);
$row = mysql_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / 20);
for ($i=1; $i<=$total_pages; $i++) {
if ($B_older==$i){
echo "". $i ." " ;
}else{
echo "". $i ." " ;
}
}
}
echo " | ";
echo " ";
?>
|
|