View Full Version : signatures in pms
Boofo
09-18-2005, 11:10 PM
Is there any way to do a plug-in to be able to use a profile field to turn signatures on/off for pms? The old way of doing it required adding the condition to the end of the build sig statement (you know what I mean, Kirby ;)). There's no hook even close to that part in private.php. Any ideas? ;)
Andreas
09-18-2005, 11:16 PM
> (you know what I mean, Kirby )
Actually I don't, but I am not sure if that matters anyway ;)
postbit_display_complete
if (THIS_SCRIPT == 'private' AND $this->registry->userinfo['fieldxx'] == 'No')
{
unset($post['signature'];
}
Or smth. like this?
Boofo
09-18-2005, 11:24 PM
I was referring to the build sig statement line. LOL I'm sure there was a better way to describe it. ;)
That should do it, but will that work with a yes or no option?
I keep froegtting that the postbit and pm stuff is all together now. ;)
EDIT: Yes it will. I just scrolled the box and saw No. :)
Andreas
09-18-2005, 11:26 PM
You might have to tweak the condition, but otherwise it should work.
Boofo
09-18-2005, 11:31 PM
You might have to tweak the condition, but otherwise it should work.
Tweak it? You mean because of the $this->registry->userinfo part?
I'll play with it but I'm sure it will work. Thank you, sir. ;)
Boofo
09-19-2005, 01:56 AM
Ok, here's what I got and I can't get it to work, As a matter of fact, even with this disabled, my signature doesn't show up in pms (to myself, since that is all I checked it with).
Profile Field 11
Type: Multiple Selection Checkbox
Options: No, do not show my signature in private messages.
And a setting in the vb options defaulting to 11.
Here's the code I am using:
$sigpms_field = "field{$vbulletin->options[sigpms]}";
if (THIS_SCRIPT == 'private' AND $this->registry->userinfo["$sigpms_field"] != 1)
{
unset($post['signature']);
}
What else could be stopping the sigs from showing up in pms?
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.