Quote:
Originally Posted by karlm
This code still causes a d/b error.
For some reason, and I'm no coder so can't say why, it is still trying to look up a table called my_database_name instead of an existing table within the database. It makes no sense.
Whereas previously (using code2) it would ask for a table called "my_database_name.vb" it now asks for a table, which also does not exist, called "my_database_name.blog"
|
sir , my code Queries from table blog
PHP Code:
SELECT * from blog order by dateline DESC LIMIT 20;
not from table my_database_name.blog
so I do not know from where comes the name of the table "my_database_name.blog"
if u use tableprefix in config.php this code will work with u well
PHP Code:
ob_start();
$blog_get = vB::$db->query_read("
SELECT * from " . TABLE_PREFIX . " blog order by dateline DESC LIMIT 20");
$output_bits = '';
while($blog = vB::$db->fetch_array($blog_get))
{
$output_bits .= '<font color="#ff0000"><b>?</b></font><a href="blog.php?b='.$blog[blogid].'">'.$blog[title].'</a></br />
<a href="member.php?u='.$blog[userid].'"><b>'.$blog[username].'</b><br />';
}
$output = $output_bits;
ob_end_clean();