MyBB Community Forums

Full Version: ProfileComments
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
(2009-06-18, 03:43 PM)Federiko Wrote: [ -> ]I have a problem: when I click on the message that appears when I have a new message in the profile, give me this error...

The link that opens is http://*mywebsite*/forum/member.php?action=profile

Do you have another plugin installed? ProfileDesign maybe?
Judging by their screenshot, the uid= is blank in the query.
It's a ProfileDesign problem. It crash with ProfileComments installed or not.
Quick fix:

Open profiledesign.php and find in line 208:
$lang->load("profiledesigns");
Add below:
if(!empty($mybb->input['uid']))
{
	$uid = intval($mybb->input['uid']);
}
elseif($mybb->user['uid'] == 0)
{
	error($lang->error_nomember);
}
else
{	
	$uid = $mybb->user['uid'];
}

Find:
$query = $db->simple_select("users", "profilebordercolor,profilebordertyp,profilebordersize,profilebg,profileimage,profileimagerepeat,theadbg,theadcolor,trow1bg,trow1color,trow2bg,trow2color,tborderbg,tborderborder,tborderbordertype,tborderbordersize", "uid= ".$_GET['uid']."", array('order_by' => 'uid', 'order_dir' => 'DESC', 'limit' => '1'));
Replace with:
$query = $db->simple_select("users", "profilebordercolor,profilebordertyp,profilebordersize,profilebg,profileimage,profileimagerepeat,theadbg,theadcolor,trow1bg,trow1color,trow2bg,trow2color,tborderbg,tborderborder,tborderbordertype,tborderbordersize", "uid= ".$uid."", array('order_by' => 'uid', 'order_dir' => 'DESC', 'limit' => '1'));
this plugin is incompatible by Referrer part.
this plugin put all users to user Referrer part.
Thanks! Smile
Nice work...Thanks.. Smile
(2009-06-18, 10:28 PM)HarryWx Wrote: [ -> ]Nice work...Thanks.. Smile

idem
Thanks all! Suggestions are welcomed Smile

(2009-06-18, 07:54 PM)Pars Wrote: [ -> ]this plugin is incompatible by Referrer part.
this plugin put all users to user Referrer part.

Emmm... what?
(2009-06-18, 07:54 PM)Pars Wrote: [ -> ]this plugin is incompatible by Referrer part.
this plugin put all users to user Referrer part.

Emmm... what?

No entendio tampoco. Maybe you should try using the referral system on your test forum, create a few "referred" test members and use your comments system to see what's going on...

Cheers,
Gene
Right! I installed "Referral in profile" (or Show Refer) today, and yes, when you visit your profile (http://localhost/mybb/member.php?action=profile) it shows all users WITOUTH a referrer.

Is the same with ProfileDesign, they don't check the $GET vars Confused
To fix it, find:
	$query = $db->simple_select("users", "username, uid", "`referrer` = '".$mybb->input['uid']."'");
Replace with:
	if(!empty($mybb->input['uid']))
	{
		$uid = intval($mybb->input['uid']);
	}
	else
	{
		$uid = $mybb->user['uid'];
	}

	$query = $db->simple_select("users", "username, uid", "`referrer` = '".$uid."'");

I don't know why are posting this here. They don't work even with ProfileComments uninstalled.