2018-01-08, 09:51 AM
A very useful plugin to us that was working in 1.6 appears to not be working as we need in 1.8. Any tips would be appreciated.
The original code:
We changed if line to:
This is because we needed certain forums to have public links. It worked great in 1.6, but in 1.8 it hides the link regardless of group or forum......
Any help with this line here to get it to work with 1.8?
Much thanks
The original code:
if ($mybb->user['uid'] == 0)
{
$lang->load('registeredlinks');
$lang->reglinks_text = str_replace("{bburl}",$mybb->settings['bburl'],$lang->reglinks_text);
$message = preg_replace('#<a href="(.*?)</a>#i', $lang->reglinks_text, $message);
}
We changed if line to:
if($forum['pid'] != 70 && !in_array($forum['fid'], array(100,140,68,78,39,159,56,160)) && in_array($mybb->usergroup['gid'], array(1, 5, 7, 12)))
{ ......
This is because we needed certain forums to have public links. It worked great in 1.6, but in 1.8 it hides the link regardless of group or forum......
Any help with this line here to get it to work with 1.8?
Much thanks