$dbUser = "silkcash_admin";
$dbPass = "Druid2469";
$dbTable = "silkcash_galgen";
$connection = @mysql_connect("localhost",$dbUser,$dbPass) or die ("Cannot login to Database");
$getDB = @mysql_select_db($dbTable,$connection) or die ("Cannot connect to database");
$showdesc = $_REQUEST['showdesc'];
$affiliate = $_REQUEST['affiliate'];
// Show/Hide Descriptions
if ($showdesc == 'yes') {
echo("Hide Descriptions ");
} else {
echo("Show Descriptions ");
};
?>
// Print Links
$sql = "SELECT * FROM links ORDER BY niche";
$result = mysql_query($sql,$connection);// or die("Can't execute query $sql");
while ($row = mysql_fetch_array($result)){
$URLer = $row['URL'];
if ($showdesc=='yes') {
$Desc = " - " . $row['description'];
};
$niche = $row['niche'];
if ($niche == $lastniche){
echo("$URLer?=$affiliate$Desc ");
} else {
echo(" $niche $URLer?=$affiliate$Desc ");
};
$lastniche = $niche;
}
?>
|