PDA


View Full Version : Signature in news topics


Lord Katsuhito
03-19-2007, 12:52 PM
When I enable the signature featuer in the news topics on my site. it uses the person that last posted sig for every thing? I will give an example

alittle bit on this. I just converted to vB from an Invision board. I donno if that would have anything to do with it or not. But as you can see in the screenshot below that it shows up the first members sig.

Brian
03-19-2007, 01:33 PM
Thanks for pointing this out. It looks like there's a problem with the variable we're using for the signature cache. If you'll look in your forum/modules/news.php file for this code though:
// Signature
$show['signature'] = false;
if ($mod_options['portal_news_showsignature'] AND $news['showsignature'] AND trim($news['signatureparsed']))
{
$show['signature'] = true;

if (!$cachedsigs[$news['userid']])
{
$cachedsigs[$news['userid']] = $bbcode_parser->parse($news['signature'], 'signature', true, false, $news['signatureparsed'], $news['sighasimages'], true);
}

$news['signature'] =& $cachedsigs[$news['userid']];
}



Replace with this:
// Signature
$show['signature'] = false;
if ($mod_options['portal_news_showsignature'] AND $news['showsignature'] AND trim($news['signatureparsed']))
{
$show['signature'] = true;

if (!$cachedsigs[$news['postuserid']])
{
$cachedsigs[$news['postuserid']] = $bbcode_parser->parse($news['signature'], 'signature', true, false, $news['signatureparsed'], $news['sighasimages'], true);
}

$news['signature'] =& $cachedsigs[$news['postuserid']];
}

And that should take care of the problem.