keyser_soze Posted April 15, 2009 Share Posted April 15, 2009 hello, i'm new in web programming and encountering a problem in php or mysql, i think i have a little error with my code below<?phpecho 'hello world';$link = mysql_connect("localhost","admin","admin");if (!$link){ die('Could not connect: ' . mysql_error());}echo 'connection success';mysql_close($con);?>when i tried to run the code above, only the 'hello world' string was displayed in the browser, I don't have any idea on what the result of mysql_connect was, i run mysql using '/etc/init.d/mysql start' then i add the user admin but, the error still occur, what might be the problem? FYI im using openSuse,Thank You in advance Link to comment Share on other sites More sharing options...
Ingolme Posted April 15, 2009 Share Posted April 15, 2009 You should edit your post so that people don't get confused that you double-posted the topic. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.