stutego Posted November 30, 2012 Share Posted November 30, 2012 please friends i have been trying to fetch data from my database but my output is showing a blank page this are my codes ?php $host_name = "localhost"; $user_name = "root"; $password = ""; $db_name = "addressbook"; mysql_connect("$host_name", "$user_name", "$password"); mysql_select_db("$db_name"); $result = mysql_query("SELECT * FROM bestway"); ?> its just showing a blank page i cant tell why Link to comment https://forums.phpfreaks.com/topic/271397-sql-problem/ Share on other sites More sharing options...
MDCode Posted November 30, 2012 Share Posted November 30, 2012 mysql_query does not do anything but execute the query. If you wish to display anything I suggest look into mysql_fetch_assoc, mysql_result, mysql_fetch_array, and echo. Link to comment https://forums.phpfreaks.com/topic/271397-sql-problem/#findComment-1396442 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.