Quote:
if ($vbulletin->options['recent_thanks_notif'] AND $vbulletin->options['recent_thanks_on_off']){
$quer = "SELECT recent_thankact FROM " . TABLE_PREFIX . "user WHERE userid = ".$vbulletin->userinfo['userid']." AND recent_thankact=1";
$temp = $db->query_read($quer) or die("Error: ". mysql_error(). " with query ". $quer);
$isthere = mysql_num_rows($temp);
if($isthere){
$recent_thankact_checked = 'checked="checked"';
}
else {$recent_thankact_checked='';
}
$templater = vB_Template::create('recent_thanks_ufield');
$templater->register('recent_thankact_checked', $recent_thankact_checked);
$templater->register_page_templates();
$template_hook[usercp_options_messaging] .= $templater->render();
}
|
Getting this error message in vb4.2.1
Warning: mysql_num_rows() expects parameter 1 to be resource, object given in [path]/profile.php(2083) : eval()'d code on line 4
Quote:
Originally Posted by Scandal
Try another one replace to the plugin with:
PHP Code:
if ($vbulletin->options['recent_thanks_notif'] AND $vbulletin->options['recent_thanks_on_off']){
$isthere = $db->num_rows($db->query_read("SELECT recent_thankact FROM " . TABLE_PREFIX . "user WHERE userid = ".$vbulletin->userinfo['userid']." AND recent_thankact=1"));
if($isthere){
$recent_thankact_checked = 'checked="checked"';
}
else {$recent_thankact_checked='';
}
$templater = vB_Template::create('recent_thanks_ufield');
$templater->register('recent_thankact_checked', $recent_thankact_checked);
$templater->register_page_templates();
$template_hook[usercp_options_messaging] .= $templater->render();
}
Hope it will fix the problem.
|
Parse error: syntax error, unexpected '<' in /home1/******************/profile.php(2083) : eval()'d code on line 15
Thanks for the mod and support.