this is my PHP code
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php
$mylink=mysql_connect("localhost", "root", "12456"
mysql_select_db("elementary", $mylink);
$sql="select * from elementary";
$result=mysql_query($sql);
while($myarray=mysql_fetch_array($result))
{
}
?>
</body>
</html>
web server gives me an error
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in f:\database\test.php
on line 13 while($myarray=mysql_fetch_array($result))
how can i solve this problem??
thanks for your help
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php
$mylink=mysql_connect("localhost", "root", "12456"
mysql_select_db("elementary", $mylink);
$sql="select * from elementary";
$result=mysql_query($sql);
while($myarray=mysql_fetch_array($result))
{
}
?>
</body>
</html>
web server gives me an error
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in f:\database\test.php
on line 13 while($myarray=mysql_fetch_array($result))
how can i solve this problem??
thanks for your help