|
Post by Martyn Dale (PB Support) on Jun 11, 2005 18:24:34 GMT
In order to hide your saybox from guests on your proboard, add the following code to the top of your headers
<script> if (pb_username == 'Guest') { document.write('<style>#shoutbox {display: none;}</style>'); } </script>
Add your usual saybox code as follows:
<div id="shoutbox"> SAYBOX CODE </div>
|
|
|
Post by grchjeff on Jun 21, 2005 4:48:26 GMT
great code man...
|
|
|
Post by ringading on Jun 29, 2005 10:53:51 GMT
Will it work for ConForums?
|
|
|
Post by real_decimic on Jun 29, 2005 23:35:30 GMT
Will it work for ConForums? No, because Conforums (and Suddenlaunch) uses PBv2.
|
|
|
Post by Martyn Dale (PB Support) on Jul 3, 2005 15:03:38 GMT
For Suddenlaunch and Conforums make the 1st code as follows:
<script> var username = 0; getUser= document.getElementsByTagName('A'); for (a=0;a<getUser.length;a++){ if (getUser[a].href.indexOf('action=profile&username=') != -1){ username = getUser[a].href; }} if (username==0) document.write('<style>#shoutbox {display: none;}</style>'); </script>
For Hyperboards make the 1st code:
<script> var username = 0; getUser= document.getElementsByTagName('A'); for (a=0;a<getUser.length;a++){ if (getUser[a].href.indexOf('action=logout') != -1){ username = getUser[a].href; }} if (username==0) document.write('<style>#shoutbox {display: none;}</style>'); </script>
|
|
rbailey
New Member
I don't suffer from addiction to Robert Redford. I enjoy every minute of it.
Posts: 10
|
Post by rbailey on Aug 9, 2005 16:39:21 GMT
do you put this code to hide users from seeing in the global or main header? Because I put it in my global header and it doesnt prevent non members from viewing.
|
|
rbailey
New Member
I don't suffer from addiction to Robert Redford. I enjoy every minute of it.
Posts: 10
|
Post by rbailey on Aug 9, 2005 17:10:16 GMT
In order to hide your saybox from guests on your proboard, add the following code to the top of your headers <script> var username = 0; getUser= document.getElementsByTagName('A'); for (a=0;a<getUser.length;a++){ if (getUser[a].href.indexOf('action=viewprofile') != -1){ username = getUser[a].href; }} if (username==0) document.write('<style>#shoutbox {display: none;}</style>'); </script> Add your usual saybox code as follows: <div id="shoutbox"> SAYBOX CODE </div> do I put this in my headers too or footers? Global or Main headers?
|
|
|
Post by Fredy on Aug 9, 2005 17:28:14 GMT
depends where u put ur saybox. if you put ur saybox in global, put the code in global headers. if its in main, put it in main headers.
|
|
rbailey
New Member
I don't suffer from addiction to Robert Redford. I enjoy every minute of it.
Posts: 10
|
Post by rbailey on Aug 9, 2005 17:49:00 GMT
I have it in global but the saybox still shows up to non members.
Do I also add the other code below? <div id="shoutbox"> SAYBOX CODE </div>
|
|
|
Post by Fredy on Aug 9, 2005 17:51:34 GMT
yes thats y he said 2 lol
|
|
rbailey
New Member
I don't suffer from addiction to Robert Redford. I enjoy every minute of it.
Posts: 10
|
Post by rbailey on Aug 9, 2005 22:55:45 GMT
well, where does one put the "usual saybox" code at ? headers/footers, right below the code? I'm putting the code in the global headers. I tried all of them and I get showing "SAYBOX CODE" appearing on the forum. AUGH!
|
|
|
Post by Fredy on Aug 10, 2005 1:00:08 GMT
omg your doing it wrong then :\
let me refrase the code for you:
put your saybox username where it says username
|
|
|
Post by Cell 2Dee on Aug 13, 2005 23:34:41 GMT
is there a way to hide it from guests on Invisionfree? im having trouble with a spammer lol
|
|
|
Post by Fredy on Aug 14, 2005 0:09:53 GMT
ban the spammers ip adress
|
|
|
Post by chatterboxesmeuk on Aug 14, 2005 3:45:01 GMT
How do you ban guests viewing on a phpbb forum please?
|
|