Thanks so much for the help
This phase of my tarantula database project has really slowed everything down. Learning PHP code is way more difficult than setting up the database.
I am trying to match my php code up with the form found here. http://www.tarantuladatabase.com/***...es/search.html The big problem is that I've done so much guess work with the database that I'm not sure if its even set up like I need it to be.
But aside from that I have a php file called connect.php that is working and connecting to my database after my file path issue got in order. I also have a file called echo.php that contains my non working php code.
Quote:
|
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/e0120590/public_html/tarantuladatabase.com/assets/php/echo.php on line 43
|
This is my php code
Code:
<?
include("connect.php");
// now you are connected and can query the database
$request = mysql_query("select field1,field2 from table");
// loop through the results with mysql_fetch_array()
while($row = mysql_fetch_array($request)){
echo $row[0]." / ".$row[1]."<br>\n";
}
// don't forget to close the mysql connection
mysql_close();
?>
Its just a copy and paste gig I got off of some php link I was reading. All i changed was the path to my connect.php file and the $results to $request so I expected the errors and now..
I'm just trying to find out if my database has enough information in it to even be search able? http://www.tarantuladatabase.com/fv.jpg and what I need to do to get my php file talking to it?
Any advice or links or anything to point me on the right track would be great. I have been reading and trying to learn php but its really confusing me hehe
|