SQL ERROR [ mysqli ]

Download and support for PhpBB3 Top Stats Mod
User avatar
Stoker
Site Admin
Site Admin
Posts: 3521
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

SQL ERROR [ mysqli ]

Post by Stoker »

RMcGirr83 wrote:For starters using quote for coloring purposes
WHERE ' . $db->sql_in_set('t.forum_id', $flist) . ' AND topic_moved_id = 0 AND topic_approved
ORDER BY topic_last_post_time DESC';
I dont understand what you mean. Can you give me a copy and paste example?

RMcGirr83 wrote:you are missing the table delineation (aka t) and topic_approved should have a value....eg

Code: Select all

		WHERE ' . $db->sql_in_set('t.forum_id', $flist) . ' AND t.topic_moved_id = 0 AND t.topic_approved = 1
		ORDER BY t.topic_last_post_time DESC';
Thanks, I understand this part :)

RMcGirr83 wrote:

Code: Select all

and forum_type = 1
should be

Code: Select all

AND forum_type = ' . FORUM_POST . '
Wouldnt that result in categories being displayed?


RMcGirr83 wrote:The tabbing is also off within this file

Code: Select all

if (!defined('INCLUDES_FUNCTIONS_TOP_STATS_PHP'))
{
	define('INCLUDES_FUNCTIONS_TOP_STATS_PHP', true);
	
	$flist = $auth->acl_getf('f_read', true);
	$flist = array_unique(array_keys($flist));
	
// Recent Active Topics
if (!empty($config['tsrat_enable']) && sizeof($flist))
{
which is more of a readability thing than anything else and indent is your friend!! :)
I will try look harder. But I cant find any problems with the tabbing.
Board rules! No PM support
User avatar
doktornotor
BBCoder IV
BBCoder IV
Posts: 167
Joined: 14 Sep 2011, 23:20
BBCodes: 30
Favourite MOD: Thanks for Posts
Contact:

SQL ERROR [ mysqli ]

Post by doktornotor »

Stoker wrote:
RMcGirr83 wrote:For starters using quote for coloring purposes
I dont understand what you mean. Can you give me a copy and paste example?
LOL. He meant that you can use colors in quote tags (unlike in code tags) to highlight the problematic parts so the post is easier to read and the issue is more visible... There is nothing to c'n'p here. :D
Support requests via PM go straight to /dev/null!
User avatar
RMcGirr83
BBCoder III
BBCoder III
Posts: 104
Joined: 08 Mar 2010, 13:17
Favourite MOD: mChat
Contact:

SQL ERROR [ mysqli ]

Post by RMcGirr83 »

Wouldnt that result in categories being displayed?
within the constants.php file FORUM_POST === 1, FORUM_CAT === 0

Code: Select all

define('FORUM_CAT', 0);
define('FORUM_POST', 1);
define('FORUM_LINK', 2);
User avatar
Stoker
Site Admin
Site Admin
Posts: 3521
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

SQL ERROR [ mysqli ]

Post by Stoker »

Thanks for the heads up :thumb:
Board rules! No PM support
Locked