Code: Select all
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>KOW Champions</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="black" text="white">
<script language=JavaScript>
<!--
//Disable right mouse click Script
//By Maximus (maximus@nsimail.com) w/ mods by DynamicDrive
//For full source code, visit http://www.dynamicdrive.com
var message="All property of KOW is trademarked and copyrighted. ";
///////////////////////////////////
function clickIE4(){
if (event.button==2){
alert(message);
return false;
}
}
function clickNS4(e){
if (document.layers||document.getElementById&&!document.all){
if (e.which==2||e.which==3){
alert(message);
return false;
}
}
}
if (document.layers){
document.captureEvents(Event.MOUSEDOWN);
document.onmousedown=clickNS4;
}
else if (document.all&&!document.getElementById){
document.onmousedown=clickIE4;
}
document.oncontextmenu=new Function("alert(message);return false")
// -->
</script>
<?php
// Connects to your Database
$link = mysql_connect("?", "?", "?") or die(mysql_error());
mysql_select_db("?",$link) or die(mysql_error());
if (!mysql_select_db("?", $link)) {
echo 'Could not select database';
exit;
}
//Define the query
$query = 'SELECT * FROM titles';
if ($r = mysql_query ($query)){ // Run the query.
// Retrieve and print every record
while ($row = mysql_fetch_array ($r)){
print '<center><h2><font color="white"><a href="title.php?id=' . $row['id'] . '">'.$row['titlename'].'</a></font></h2></center>';
print '<center><h4><font color="white"><a href="bios.php?id=' . $row['id'] . '">'.$row['champion'].'</a></font></h4></center>';
print '<center><font color="white"><u>Contenders</u></font></center>';
print '<center><font color="white"><a href="bios.php?id=' . $row['id'] . '">'.$row['contender1'].'</a></font></center>';
print '<center><font color="white"><a href="bios.php?id=' . $row['id'] . '">'.$row['contender2'].'</a></font></center>';
print '<center><font color="white"><a href="bios.php?id=' . $row['id'] . '">'.$row['contender3'].'</a></font></center>';
}
} else {
die ('<p>Could not retrieve the data because <b>' . mysql_error() . '</b>. The query was $query.</p>');
} //End of query IF
?>
</body>
</html>