Monday, 15 September 2014

Display all tables from MySQL database in PHP -



Display all tables from MySQL database in PHP -

so code right now:

$mysqli = new mysqli("localhost", "username", "password", "dbname"); // connect if (mysqli_connect_errno()) { // checking connection printf("connect failed: %s\n", mysqli_connect_error()); exit(); }

so, there several tables in database. want display name of of tables. i've been searching on net while, couldn't find right answer. in advance!

the sql statement want is:

show tables;

php mysql

No comments:

Post a Comment