Code: Select all
Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in \db\mysql4.php on line 302
Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in \db\mysql4.php on line 302
No solution yet !!, You just suppress the warning...Why nobody can fix the problem?IPB_Refugee wrote:Ah,
you haven't read page 32 of this thread, right?![]()
http://www.phpbb.com/community/viewtopi ... 3#p2905813
Regards
Wolfgang
Code: Select all
#
#-----[ FIND ]------------------------------------------------
#
$template->assign_vars(array(
#
#-----[ BEFORE, ADD ]------------------------------------------------
#
// Anti Bot Question Mod - Start
if ($abq_config['abq_register'])
{
$abq_email_variable_name = $abq_config['email_variable_name'];
}
else
{
$abq_email_variable_name = 'email';
}
// Anti Bot Question Mod - End
Code: Select all
$template->assign_vars(array(
Code: Select all
Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in \db\mysql4.php on line 302
Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in \db\mysql4.php on line 302
Code: Select all
$dbms = 'mysql';
I bit the bullet and went for the first instance and it proved correct! I seem to have installed and configured the MOD correctly and manually at first attempt, something this topic almost put me off doing. It was laborious but very rewarding. Not a single spammy posting since and 24 bogus registrations intercepted in a week.dozza wrote:Which instance should I add the new code before, or does FIND imply all instances?
Code: Select all
Fatal error: Call to a member function on a non-object in /var/www/vhosts/mywebsite/httpdocs/phpBB2/includes/functions.php on line 349
Code: Select all
// Anti Bot Question Mod - Start
include($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_abq.' . $phpEx);
$abq_config = array();
$sql = "SELECT *
FROM " . ANTI_BOT_QUEST_CONFIG_TABLE;
[color=#FF0000]if( !($result = $db->sql_query($sql)) )[/color]
{
message_die(CRITICAL_ERROR, "Could not query anti bot question mod config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
$abq_config[$row['config_name']] = $row['config_value'];
}
// Anti Bot Question Mod - End
This one was quite annoying, but after tracking the variable through the different steps I decided it was being passed to the functions_validate.php file as an empty variable. To fix this I made the change below.Sorry, but this e-mail address is invalid.
Code: Select all
#
#-----[ OPEN ]------------------------------------------------
#
includes/usercp_avatar.php
#
#-----[ FIND ]------------------------------------------------
#
if ($abq_config['abq_register'])
{
$params[] = $abq_config['email_variable_name'];
$$abq_config['email_variable_name'] = $email;
#
#-----[ REPLACE WITH ]----------------------------------------
#
if ($abq_config['abq_register'])
{
$params[] = $abq_config['email_variable_name'];
$abq_config['email_variable_name'] = $email;
This one was much easier...just need to help it out a little and tell it what $db is.Fatal error: Call to a member function on a non-object in /*******/forum/includes/functions.php on line 348
Code: Select all
#
#-----[ OPEN ]------------------------------------------------
#
includes/functions.php
#
#-----[ FIND ]------------------------------------------------
#
$abq_config = array();
$sql = "SELECT *
FROM " . ANTI_BOT_QUEST_CONFIG_TABLE;
#
#-----[ REPLACE WITH ]----------------------------------------
#
global $db;
$abq_config = array();
$sql = "SELECT *
FROM " . ANTI_BOT_QUEST_CONFIG_TABLE;