onlyME Posted September 7, 2011 Posted September 7, 2011 File Name: (Bim) Top New Posts in Mobile SkinFile Submitter: DoremonFile Submitted: 06 Sep 2011File Category: Hooks and Plugins Show new posts or new topic in mobile skin. " alt="" class="ipsImage" width="1000" height="362"> Click here to download this file
Bartek Posted October 15, 2011 Posted October 15, 2011 Can I set if up to show only topics where user have permission to view?
AZanetti Posted December 19, 2011 Posted December 19, 2011 Groups that do not have permission can see the title
Adriano Faria Posted December 19, 2011 Posted December 19, 2011 Hi there, onlyME. Since I'm using it on my board, decided to post here a tiny change in your script to fix the permission issue. Find in your XML: $bimforum = explode(',', $this->settings['bim_topnewposts_mobile_forum'] ); if( count( $bimforum ) ) { $iwhere = 'forum_id IN (' . implode(',', $bimforum ). ')'; } Change to: $forumIdsOk = $this->registry->class_forums->fetchSearchableForumIds(); if( !is_array($forumIdsOk) OR !count($forumIdsOk) ) { return ''; } else { $iwhere = 'forum_id IN (' . implode(',', $forumIdsOk ). ')'; } Now users will only see topics that they have permission to see and makes the setting Forums?. uselless... Unless you want to add a setting to EXCLUDE forums... so it's enough to add: $bimforum = explode(',', $this->settings['bim_topnewposts_mobile_forum'] ); if( count( $bimforum ) ) { $iwhere2 = 'forum_id NOT IN (' . implode(',', $bimforum ). ')'; } You just need now to add $iwhere2 on 'where' query.
Bartek Posted December 19, 2011 Posted December 19, 2011 If author can upload this changes to original mod file and post as upgrade. Thank you.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.