Version: 0.0.1, by Atakan KOC
Developer Last Online: Mar 2023
Category: Board Optimization -
Version: 3.6.8
Rating:
Released: 12-15-2006
Last Update: 12-15-2006
Installs: 116
Uses Plugins
No support by the author.
Forum Archive List Forum Footer
install
Go to your admin cp, then:
Plugin System -> Manage Products -> [Add/Import Product] -> Select 'Product-falf.xml' from your computer then press 'Import'
@Atakan KOC - Is there any way to add permissions to this so only the links that are viewable to the viewing user are displayed?
Here you go, Boofo. Here's two versions, both tested on 3.6.8.
Both show links based on what the user has permission to see. product-falf-perms-all.xml shows the archive links to all users, while product-falf-perms.xml only shows the links to guests (group 1).
*Both products now also include the photoplog fix* You'll need to uninstall Atakan KOC's original product before installing either of these.
Basically, for the permissions part, I changed:
Code:
foreach ($vbulletin->forumcache AS $forum)
{
$forum_sira[$forum['forumid']] = $forum['forumid'];
}
to:
Code:
foreach ($vbulletin->forumcache AS $forum)
{
$forumpermas = $vbulletin->userinfo['forumpermissions'][$forum['forumid']];
if (($forumpermas & $vbulletin->bf_ugp_forumpermissions['canview']) OR ($forumpermas & $vbulletin->bf_ugp_forumpermissions['canviewthreads']) OR ($forumpermas & $vbulletin->bf_ugp_forumpermissions['canviewothers']))
{
$forum_sira[$forum['forumid']] = $forum['forumid'];
}
}
Here you go, Boofo. Here's two versions, both tested on 3.6.8.
Both show links based on what the user has permission to see. product-falf-perms-all.xml shows the archive links to all users, while product-falf-perms.xml only shows the links to guests (group 1).
You'll need to uninstall Atakan KOC's original product before installing either of these.
Basically, for the permissions part, I changed:
Code:
foreach ($vbulletin->forumcache AS $forum)
{
$forum_sira[$forum['forumid']] = $forum['forumid'];
}
to:
Code:
foreach ($vbulletin->forumcache AS $forum)
{
$forumpermas = $vbulletin->userinfo['forumpermissions'][$forum['forumid']]; if (($forumpermas & $vbulletin->bf_ugp_forumpermissions['canview']) OR ($forumpermas & $vbulletin->bf_ugp_forumpermissions['canviewthreads']) OR ($forumpermas & $vbulletin->bf_ugp_forumpermissions['canviewothers'])) {
$forum_sira[$forum['forumid']] = $forum['forumid'];
}
}
The fix has now been added to both products and my post has been edited to reflect this.
Excellent! I just didn't like the idea of listing forums for people who couldn't see them as then the questions start as to what is in there and why can't they access them. Thanks again.
Excellent! I just didn't like the idea of listing forums for people who couldn't see them as then the questions start as to what is in there and why can't they access them. Thanks again.
No problem, glad I could help.
Quote:
Originally Posted by Tom_S
That's because you da man! Thanks!
I would've put it in sooner if I had realised it was such a simple fix. I don't have photoplog so I kinda skipped your posts...
I took out this code as I couldn't figure out what it was doing in there. The permissions still work fine without it.
Code:
if (is_member_of($vbulletin->userinfo, 1)){
That's there to hide the archive links from registered users. I don't know about your site(s) but mine has a dark black background with yellow links, so they stand out a fair way, and I don't really want regged users going into the archive when it's mainly for search engine bots.
I did upload 2 versions though, one with that, one without, so it's your choice.