|
Post by Wormopolis on Dec 2, 2009 3:48:29 GMT -8
version upgrade: 1.21 added in a exempt user list in case someone needs to be exempt
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 2, 2009 5:53:52 GMT -8
No, that's OK. I just thought it would be a bit annoying if it popped up every time you logged in. Thanks for the reply.
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 9, 2009 12:28:22 GMT -8
Hi If I want to delete this message completely, (line 29 ) portalMessage+="6. All codes are done by volunteer basis, and for free. You get what you pay for.<br> </td></tr></table>"; how much of it, if any, do I need to move to the previous line? It's the bit in bold that worries me.
|
|
|
Post by Wormopolis on Dec 9, 2009 13:06:19 GMT -8
the bold stuff in line 29 was to close off the stuff at the beginning of line 23, so you will need to keep it. you can omit the text before the <br>.
the entire portalMessage variable is just HTML really. I broke it up to make it easier to see the editing, but you dont have to if you dont want to. just make sure you escape any " characters if you have them inside or you will get an error.
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 9, 2009 13:14:47 GMT -8
Great! Thank you! ;D I'm sure I'll be back.
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 10, 2009 8:03:41 GMT -8
I'm not sure if I should be asking here or on PB Support, but here goes. emmysguysandgalls.proboards.comIt looks fine on the test link, but I looged out and went to IE to sign in with a user name that hadn't logged in for over 60 days, and I got the screen that new members registering should get. I cleared cookies and tried to register and went straight to the registration screen. I'm assuming the splash screen should appear before that. Also the test link is visible at all times.
|
|
|
Post by Wormopolis on Dec 10, 2009 10:50:55 GMT -8
test link will be visible at all times, but ONLY for admin.
and by all means, if it involves one of my codes, asking here will garner my attention faster then support.
the way it works: the first time you see the portkey message (not from test) it places a cookie on your computer with the date.
if you dont log on for however many days, the next time you log in, prtkey will read the stored date from the cookie and display portkey if the number is exceeded. Then it updates the cookie with a new date.
if you are banned, it places a special value in the cookie that says you were banned. the next time you log in (and arent still banned), portkey will read the banned flag in the cookie and display the portkey message. then it will update the cookie with a new date (erasing the ban flag).
as for it not showing the portkey after you cleared cookies, that is a new one for me. I will have to seeif I can recreate that.
|
|
|
Post by Wormopolis on Dec 10, 2009 10:53:51 GMT -8
oh.. der.. it wont work on registrtion screen because its set to not show for guests, only registered members. as soon as the account is registered and logged in, the portkey should pop up.
|
|
|
Post by Wormopolis on Dec 10, 2009 10:59:47 GMT -8
sigh... I apparently pasted the wrong version into the first post. you are correct, it does indeed show the portkey test for everyone. I wrote it originally without the admin check for testing and apparently forgot to put the check back into the code I posted.
find this line:
document.getElementById('linkspace').appendChild(adLink);
change to:
if (pb_username=='admin') document.getElementById('linkspace').appendChild(adLink);
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 10, 2009 11:42:42 GMT -8
Now the link has disappeared altogether, BUT, there are three admin and none of us use the user name 'admin'. Should I change that to the names I put in as exempt, separated by a '|'?
If so is there anything else I need to change as well?
|
|
|
Post by Wormopolis on Dec 10, 2009 11:53:18 GMT -8
oh. yeah it would only show the link to username admin.
if you want it to show to a list of users it has to be:
if (pb_username.match(/^(user1|user2|user3)$/) )document.getElementById('linkspace').appendChild(adLink);
if the test looked fine, you should be set!
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 10, 2009 12:31:48 GMT -8
if(pb_username.match(/^(swifty|mary|ericslover|atomicwitch)$/))document.getElementById('linkspace'). appendChild(adLink); That's what I have, still no test link.
I know I said 3 admin. I forgot about me. ;D
There are only 3, but the main admin uses a sceen name foe posting.
|
|
|
Post by Wormopolis on Dec 10, 2009 12:43:12 GMT -8
you have it appearing on 2 lines...
if (pb_username.match(/^(swifty|mary|ericslover|atomicwitch)$/))document.getElementById('linkspace'). appendChild(adLink);
it should all be 1 line:
if (pb_username.match(/^(swifty|mary|ericslover|atomicwitch)$/))document.getElementById('linkspace').appendChild(adLink);
|
|
pluqui
Not New Member
Posts: 10
pluqui said 0 great things
|
Post by pluqui on Dec 10, 2009 12:52:27 GMT -8
I can't get it all on one line. if (first line) (pb_username.match(/^(swifty|mary|ericslover|atomicwitch)$/))document.getElementById('linkspace').app (second line) endChild(adLink); (third line) I put back the orginal line and it's not working. I see you have a line at 125 that I didn't have but it was working without that. This is what I have for the last few lines now but no test link. if (!pb_username.match(exemptUsers)) makePortKey(); } } adLink=document.createElement('a'); adLink.align='center'; adLink.href='javascript:void(0);'; adLink.onclick= function() {makePortKey()}; adLink.style.backgroundColor='000000'; adLink.style.color='FFFFFF'; adLink.innerHTML='PORTKEY TEST'; document.write('<div width="100%" id="linkspace" align="center"></div>'); document.getElementById('linkspace').appendChild(adLink); } // --> </script>
|
|
|
Post by Wormopolis on Dec 10, 2009 14:05:30 GMT -8
well word wrap will happen, but when I looked before you had a linefeed after appendChild. NOW you have a line that looks like this: if ((absenceMonitor=="yes" && expMsg)||(bannedMonito emmysguysandgalls.proboards.com/index.cgi?action=headersfooters2r=="yes" && banMsg)||noobMsg) { where it looks like you pasted your URL in the middle of a line? you need to undo that. delete the red. if (pb_username.match(/^(swifty|mary|ericslover|atomicwitch)$/))document.getElementById('linkspace').appendChild(adLink);
click that line and paste into the code. it should keep it to 1 line then.
|
|