include "styles.inc"; include "countdays.php"; include "dbconnect.php"; $query = "SELECT * FROM EVENTS WHERE NAME = 'Christmas' ORDER by DATE"; $result = mysql_query($query); $event_set = mysql_fetch_array($result); $event_day = substr($event_set['DATE'],-2,2); $event_month = substr($event_set['DATE'],-4,2); if (strlen($event_set['DATE'])<=5){$event_yearfix = "200".substr($event_set['DATE'],-5,1);} else {$event_yearfix = "20".substr($event_set['DATE'],0,2);} $timeinseconds=mktime(0, 0, 0, $event_month, $event_day, $event_yearfix);//next event date $epochinseconds=mktime();//time now $timedifferenceinsecs=$timeinseconds-$epochinseconds; $timeleft=time_left($timedifferenceinsecs); $timetodate=substr($timeleft,0,17); $themeitem = split(",",$event_set['THEMESET']); ?>
Products are always subject to availability at time of ordering. |
St Patrick's Day gift
Oh...the luck of the Irish! Join the St Patrick's Day celebrations this year and send something deliciously green to your friends, colleagues, clients or ex-pats. This wonderful celebration for all things Irish is available from Yummybunch.com for $69 delivered. AND don't forget, delivery is FREE Australia wide! Order NOW for delivery this week! |
$prod_count = 1;
if ($event_set['THEMESETCOUNT']==1){$howmanyunits="ID=".$themeitem[0];}
if ($event_set['THEMESETCOUNT']==2){$howmanyunits="ID=".$themeitem[0]." or ID=".$themeitem[1];}
if ($event_set['THEMESETCOUNT']==3){$howmanyunits="ID=".$themeitem[0]." or ID=".$themeitem[1]." or ID=".$themeitem[2];}
if ($event_set['THEMESETCOUNT']==4){$howmanyunits="ID=".$themeitem[0]." or ID=".$themeitem[1]." or ID=".$themeitem[2]." or ID=".$themeitem[3];}
if ($event_set['THEMESETCOUNT']==5){$howmanyunits="ID=".$themeitem[0]." or ID=".$themeitem[1]." or ID=".$themeitem[2]." or ID=".$themeitem[3]." or ID=".$themeitem[4];}
//echo $unit[0];
//$query = "SELECT * FROM PRODUCTS WHERE ID=".$unit[0]." or ID=".$unit[1]." or ID=".$unit[2]." or ID=".$unit[3]." or ID=".$unit[4]." ORDER BY RANK DESC, NAME";
//$query = "SELECT * FROM PRODUCTS WHERE ID=".$unit[0]." or ID=".$unit[1]." or ID=".$unit[2]." or ID=".$unit[3]." or ID=".$unit[4]." ORDER BY COST, RANK";
$query = "SELECT * FROM PRODUCTS WHERE ".$howmanyunits." ORDER BY COST, RANK";
//$query = "SELECT * FROM PRODUCTS WHERE QTY >= 1 ORDER BY RANK DESC, NAME";
$result = mysql_query($query);
while($prod_set = mysql_fetch_array($result)){
if ($prod_set['AVAIL']=="yes"){
$prod_origin_id[$prod_count] = $prod_set['ID'];
$prodname[$prod_count] = $prod_set['NAME'];
$proddesc[$prod_count] = substr($prod_set['DESCRIPTION'],0,80)."...";
$proddesclong[$prod_count] = $prod_set['DESCRIPTION'];
$prodcost[$prod_count] = $prod_set['COST'];
$prodimage[$prod_count] = $prod_set['IMAGE'];
$prodthumb[$prod_count] = $prod_set['THUMB'];
$prodavail[$prod_count] = $prod_set['AVAIL'];
$prodrank[$prod_count] = $prod_set['RANK'];
$prod_count++;
}
}
$tempthemecount = 1;
while(($tempthemecount<=$event_set['THEMESETCOUNT'])&&($tempthemecount<5)){
?>
echo $prodname[$tempthemecount];?> $tempthemecount++; } ?> |
The problem:
How do you get 2 kilograms of chocolate home from the shops in a hot car?
The solution: Eat it in the parking lot OR have Yummybunch.com deliver it FREE today. |