Simple Machine Codes
April 19, 2024, 05:56:06 am
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to SMC, the best place for your SMF For Free Codes
 
  Home Help Search Arcade Gallery Affiliates Code Index Staff List Calendar Members Login Register  

Certain Boards For Certain Members

Pages: [1]   Go Down
  Print  
Author Topic: Certain Boards For Certain Members  (Read 579 times)
0 Members and 1 Guest are viewing this topic.
Agent Moose
Administrator

Offline Offline

Gender: Male
Posts: 2,672



View Profile WWW
« on: June 24, 2008, 10:17:05 am »

Footers:
Code:
<script>
function CertainBoards(Board,Name){
var username = $("td.titlebg2 span b").not($("td.titlebg2 span b:contains(News)")).html();
if(!username == Name){
$("a[name='b" + Board + "']").parent().parent().parent().hide();
};};};
CertainBoards("BOARD ID","USERNAME");
</script>

This should work ,but I don't know, I havn't tested it due to time.
BOARD ID = The Board number that you want the user to see
USERNAME = The User to see it.

Just add more of these lines to show boards to certain people:
CertainBoards("BOARD ID","USERNAME");

Original Request: http://smcodes.smfforfree3.com/index.php/topic,1053.0.html

Enjoy Smiley
« Last Edit: June 24, 2008, 10:17:34 am by Agent Moose » Report Spam   Logged

Share on Facebook Share on Twitter

legend 1234
100 Club Member

Offline Offline

Gender: Male
Posts: 461


Legend 1234


View Profile WWW
« Reply #1 on: June 28, 2008, 10:16:02 pm »

very nice moosey thanks alot

legend 1234
Report Spam   Logged

Nuggett420
Starter

Offline Offline

Posts: 18


View Profile
« Reply #2 on: July 01, 2008, 05:17:52 am »

so how do i tell what the board number is? do i just count down all the boards till i reach the one or what? also to add more members to view the same board do i just seperate the usernames with commas and then put the new name in quotation marks etc?
« Last Edit: July 01, 2008, 05:21:35 am by Nuggett420 » Report Spam   Logged
CodeLover
100 Club Member

Offline Offline

Gender: Male
Posts: 331


View Profile
« Reply #3 on: July 01, 2008, 09:35:13 am »

To get the board number, look for this in the URL:

board,8.0.html

I'm pretty sure that's what you need.

And for your other question, let's say you wanted 3 members to view your board. You would do this:

CertainBoards("1.0","Mem1");
CertainBoards("1.0","Mem2");
CertainBoards("1.0","Mem3");
Report Spam   Logged

Don't get mad at me if I'm acting immature - I'm only 10 Grin


Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by EzPortal
Bookmark this site! | Upgrade This Forum
SMF For Free - Create your own Forum

Powered by SMF | SMF © 2016, Simple Machines
Privacy Policy