require("incl/dbcon.php");
//============find scategory2=====================
$lk=$_SERVER["REQUEST_URI"];
if($lk="/video-software-categories.html")
$lk="DVD creators";
else
{$lk=str_replace("_discount_coupons.html","",$lk);
$lk=str_replace("/","",$lk);
$lk=str_replace("-"," ",$lk);
}
// categories
$list=' ';
$query1="SELECT distinct scategory2 FROM wx WHERE scid=89 and scategory2!='n' and `vupdate`>'2010-01-01' order by scategory2";
$result1=mysql_query($query1) or die(mysql_error());
$nrows1=mysql_num_rows($result1);
$categorytable='
';
$a=0;
for ($y=0;$y<$nrows1; $y++)
{
$row=mysql_fetch_array($result1);
$scat=stripslashes($row["scategory2"]);
$scatm=str_replace(" ","-",$scat);
if($a!=3)
{$a++;
$categorytable=$categorytable.' '.$scat.' ';
}
else
{
$a=1;
$categorytable=$categorytable.' '.$scat.' ';
}}
//$query2="SELECT ProductName, ProductLink2, vendorname from `working` WHERE onsale='y' and alivevendor='y' and `vupdate`>'2009-01-01' and `scat1`='$scatfull' and onsale='y' order by productname ";
$query2="select ProdGID, ProductName, ProductLink2, ProductLink3, vendorname from wx WHERE onsale='y' and alivevendor='y' and `vupdate`>'2010-01-01' and scategory2='$lk' order by productname ";
$result2=mysql_query($query2) or die(mysql_error());
$nrows2=mysql_num_rows($result2);
$list=$list.''.$lk.' coupons and promotions: '.$nrows2.' ';
for ($i=0;$i<$nrows2; $i++)
{
$row=mysql_fetch_array($result2);
//----------update for wx--------------------
$gpid=$row["ProdGID"];
$pname2=stripslashes($row["ProductName"]);
$pname2=ucfirst($pname2);
$plink2=stripslashes($row["ProductLink2"]);
$plink3=stripslashes($row["ProductLink3"]);
$pagelink=$gpid-800000;
if($plink3!='n')
$plink2=$plink3.'_'.$pagelink;
//-----------------------------------------
$vname=stripslashes($row["vendorname"]);
$vname=ucfirst($vname);
$list=$list.''.$pname2.' ........ ( '.$vname.' ) ';
}
$list=$list.'..........Top ';
$categorytable=$categorytable.'
';
?>
Video software categories and promotional coupons.
Video Software Discount Coupons:
Categories
Pay less with discount codes, coupons, rebates and promotions
=$categorytable?>
=$list?>
require("incl/nav-dvs.php");
?>
require("incl/bot.php");
?>