acey99 Posted December 7, 2005 Share Posted December 7, 2005 ok I was told to use $q=mysql_query("SELECT DATABASE()"); to return what db i'm on, the problem is I don't know how to use this in php, any help? Quote Link to comment https://forums.phpfreaks.com/topic/3000-what-db-am-i-using/ Share on other sites More sharing options...
seanlim Posted December 8, 2005 Share Posted December 8, 2005 $q=mysql_query("SELECT DATABASE()"); $col = mysql_fetch_array($q); echo "Database: ".$col[0]; HTH Quote Link to comment https://forums.phpfreaks.com/topic/3000-what-db-am-i-using/#findComment-10085 Share on other sites More sharing options...
Arenium Posted December 11, 2005 Share Posted December 11, 2005 See the MySQL Data Retrieval section of the PHPFreaks FAQ linked in my signature. Quote Link to comment https://forums.phpfreaks.com/topic/3000-what-db-am-i-using/#findComment-10128 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.