stutego Posted November 30, 2012 Share Posted November 30, 2012 (edited) 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 Edited November 30, 2012 by stutego Quote 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. Quote Link to comment https://forums.phpfreaks.com/topic/271397-sql-problem/#findComment-1396442 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.