Hello all
im new member and newbe abiut programming.
i'd like to ask about this program.
when i run the script it show like this :
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/rekor/public_html/admin/top.php on line 6
You are not an administrator
here the script "top.php":
<?php
require '../dconn.php';
require '../require.inc.php';
$query = mysql_query("SELECT * FROM $user_table WHERE userid=$id");
$row = mysql_fetch_array($query);
if ($row["type"] != "admin") {
die ("You are not an administrator");
}
?>
<html>
<head>
<title>SuperSurf Administration: <? echo $title; ?></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF">
<table width="95%" border="0" cellspacing="0" height="245">
<tr>
<td rowspan="2" background="../images/1.jpg" width="17%" valign=top>
<p> </p>
<table width="100%" border="1" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF">
<tr align="right" bordercolor="#666666">
<td colspan="2"><img src="down.gif" width="17" height="18"></td>
</tr>
<tr bordercolor="#000000" valign="top">
<td colspan="2" height="158" valign=top>
<table width="98%" border="0" cellspacing="0" cellpadding="4" align="center">
<tr>
<td><font face="Ms Sans Serif" size="2">Users<br>
- <a href='list_users.php'>List</a><br>
- <a href='givegold.php'>Give Gold</a><br>
- <a href='emailUser.php'>Email One</a><br>
- <a href='sendmail.php'>Email All</a><br>
<a href='findcheats.php'>Find cheats</a><br>
<a href='list_websites.php'>Websites</a><br>
<a href='list_faqs.php'>FAQs</a><br>
<a href='list_ads.php'>Advertisements</a><br></font></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td width="83%" height="61" background="../images/1.jpg">
<blockquote><br>
<h2><? echo $title; ?> Administration Panel</h2>
</blockquote>
</td>
</tr>
<tr>
<td width="83%" height="124">
Thx for your help
:lol: