inherit
178150
0
Nov 19, 2012 15:15:39 GMT -8
smashwords
When I had hair.
21
March 2012
smashwords
|
Post by smashwords on Nov 13, 2012 9:13:52 GMT -8
There was a code snippet for the older version which hid the members list from everyone except admins. I don't know who wrote it.
I copied the old code into the proper locations in V5 header but it doesn't work.
Any help greatly appreciated.
Here is the code which worked in v4:
<script type="text/javascript"> // Remove 'Members' link from menu
var fStaff=/^(admin|staff1)$/; // Staff allowed to see 'Members' link.
if(!fStaff.test(pb_username)){ var mLink = document.getElementsByTagName ("a"); for (var a = 0, l = mLink.length; a < l; a ++) { if (mLink.item (a).href.match (/action=members/i)) { mLink.item (a).parentNode.removeChild (mLink.item (a).nextSibling); mLink.item (a).parentNode.removeChild (mLink.item (a)); break; } } if(pb_action=="members"){document.write("<div style='display:none;'>");} } </script>
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on Nov 15, 2012 17:40:24 GMT -8
Could you just not remove it from the navigation menu?
Admin Home > Settings > Forum Settings > Navigation
Untick "Members".
You can still visit the members page if you know the URL (/members).
|
|
inherit
178150
0
Nov 19, 2012 15:15:39 GMT -8
smashwords
When I had hair.
21
March 2012
smashwords
|
Post by smashwords on Nov 16, 2012 7:13:46 GMT -8
Thanks, Peter. I can (and have) removed Members link from menu, but found having the Members list appear for Admin only was quicker than adding the /members to url whenever I needed access to members list.
|
|