Search Results for the keyword : print $_GET['stext']; ?>
$stext=$_GET['stext'];
$hostname="localhost";
$username="root";
$password="venw037";
$dbName="cadmin_cadb";
if($conn=mysql_connect($hostname,$username,$password))
{}
else
{
die("DATABASE FAILED TO RESPOND.");
echo "
There has been an error. This is the error message:
";
echo "
" . mysql_error() . "
";
echo "Please Contant Your Systems Administrator with the details";
}
mysql_select_db($dbName, $conn);
$stext1 = substr_replace($stext,"",-1);
$stext .= "s";
$sql = "SELECT distinct coid, stid, otid, sname, sfolder, description, dealdesc, listprice, currentprice,cofferid, mir, dealimage, finalprice, code, DATE_FORMAT(enddate,'%b %d') as enddate FROM coupondeal WHERE MATCH (description) AGAINST ('{$_GET['stext']}|| $stext1||$stext' IN BOOLEAN MODE) && otid=6 order by rank desc LIMIT 0,50";
$result = mysql_query($sql);
if (!$result) {echo "Could not successfully run query ($sql) from DB: " . mysql_error(); exit;}
if (mysql_num_rows($result) == 0) {echo " ";}
$sp = "'";
while ($row = mysql_fetch_assoc($result)) {
}
mysql_free_result($result);
echo '
';
echo '
Store
';
echo '
';
echo '
Link to On-Line Coupons
';
echo '
Expiry
';
$sql = "SELECT distinct sfolder, sname, stid, coid,otid,description, cofferid, mir, code, DATE_FORMAT(enddate,'%b %d') as enddate FROM coupondeal WHERE MATCH (searchword, sname, description) AGAINST ('{$_GET['stext']}|| $stext1||$stext' IN BOOLEAN MODE) && otid<>6 group by sfolder order by rank desc LIMIT 0,50";
$result = mysql_query($sql);
if (!$result) {echo "Could not successfully run query ($sql) from DB: " . mysql_error(); exit;}
if (mysql_num_rows($result) == 0) {echo "";}
$sp = "'";
while ($row = mysql_fetch_assoc($result)) {
echo '
';
$spr=$row["coid"];
echo '
';
echo '
';
IF ($row["otid"]>5)
{echo '
';}
else
{echo '
';}
echo '
'.$row["enddate"].'
';
}
echo '';
echo '';
echo '
';
echo '';
mysql_free_result($result);
echo '
';
$sql = "SELECT distinct sfolder, sname, stid, coid,otid, description, cofferid, mir, code, DATE_FORMAT(enddate,'%b %d') as enddate FROM coupondeal WHERE description not like '%$stext1%' && otid<>6 && otid<>7 group by sfolder order by rank desc LIMIT 0,15";
$result = mysql_query($sql);
if (!$result) {echo "Could not successfully run query ($sql) from DB: " . mysql_error(); exit;}
if (mysql_num_rows($result) == 0) {echo ""; exit;}
$sp = "'";
echo '