Toggle navigation
Home
Latest pastes
FAQ
Random
BitBin is shutting down!
Register
Login
Funtion to verify if table exists in data base
SUBMITTED BY:
Guest
DATE:
March 26, 2015, 2:36 p.m.
FORMAT:
PHP
SIZE:
288 Bytes
Raw
Download
Tweet
HITS:
4933
Go to comments
Report
function table_ok($db, $table){
$query = "SHOW TABLES FROM $db";
$runQuery = mysql_query($query);
$tables = array();
while($row = mysql_fetch_row($runQuery)){
$tables[] = $row[0];
}
if(in_array($table, $tables)){
return TRUE;
}
}
?>
Please enable JavaScript to view the
comments powered by Disqus.
comments powered by
Disqus