skindstad Junior Member
Posts: 41 Status: Offline Gender: Female Location: Denmark Joined:
pmwwwmsnyahoovForum | Guests can't view profiles (20th Apr 10 at 3:44pm UTC) Resolved | | Yes, it's me again Two things, if it's possible. Otherwise the first is most important
I'm in need of a code, so guests can't view members profile. I can't seem to find one around here and since my coding skills are pretty much zero in making new, then I'm totally lost. So any help will be greatly appreaciated
And another thing. I've discovered some problems with some of my boards, where I can't open the threads. It's basically the two top boards I've got on my forum. I think it's when I use colours and font sizes and other fancy stuff in the posts, the thread won't open when I want to enter it. Thought it had something to do with a code I had added, but one of the other members had trouble with it before I had added the code, so I don't know. | |
|
|
dog199200 Guest | Re: Guests can't view profiles (20th Apr 10 at 5:47pm UTC) | | Ok about the second thing, report it to ross in the bug reports board. As for the first, umm let me see what i can do, I might be able to drag something up fairly easy. | |
|
Michael Moderator
Recoding the future Posts: 4,043 Status: Offline Gender: Male Location: UK Joined:
Additional Groups: Coding Team
pmvForum | Re: Guests can't view profiles (21st Apr 10 at 10:35am UTC) | | Bugs Boards - Please report the 2nd issue in there... and Ross will be able to resolve it for you fairly quickly. Just sounds like a problem with the UBBC parser. (Make sure to post direct links to the threads).
If Broken doesn't get part 1 done, I'll do it later | |
|
dog199200 Guest | Re: Guests can't view profiles (21st Apr 10 at 3:25pm UTC) | | I wont be able to, something came up this morning and I have to go out of town for a few days. | |
|
Michael Moderator
Recoding the future Posts: 4,043 Status: Offline Gender: Male Location: UK Joined:
Additional Groups: Coding Team
pmvForum | Re: Guests can't view profiles (23rd Apr 10 at 5:50am UTC) | | Try this:
Main Header: <table align="center" width="0" cellspacing="1" cellpadding="3" class="border" id="guest_error" style="display:none;"><tr><td class="title1"><b>An Error has Occurred</b></td></tr><tr><td class="window1"><font size="2">Guests are not allowed to view member profiles. Please <a href = './action/login'>Login</a> or <a href = './action/register'>Register</a>.</font></td></tr></table> <script type = 'text/javascript'> if(location.href.match(/\/profile\/(.+?)($|\/)/) && vf_username == 'guest'){ document.write('<div style = "display: none;">'); get('guest_error', 'id').style.display = ''; get('guest_error', 'id).width = get('table', 'tag')[0].width; } </script>
Main Footer: <script type = 'text/javascript'> if(location.href.match(/\/profile\/(.+?)($|\/)/) && vf_username == 'guest') document.write('</div>'); </script>
| |
|
Nick Very Senior Member
Posts: 3,012 Status: Offline Gender: Male Location: vForums Age: 34 Joined:
pmwww | Re: Guests can't view profiles (24th Apr 10 at 12:21am UTC) | | It works, but it's not the width of the forum it's longer than the forum. | |
|
Michael Moderator
Recoding the future Posts: 4,043 Status: Offline Gender: Male Location: UK Joined:
Additional Groups: Coding Team
pmvForum | Re: Guests can't view profiles (24th Apr 10 at 7:14am UTC) | | Altered the code. | |
|
skindstad Junior Member
Posts: 41 Status: Offline Gender: Female Location: Denmark Joined:
pmwwwmsnyahoovForum | Re: Guests can't view profiles (26th Apr 10 at 9:45am UTC) | | It doesn't work in my end. I can still see the members profiles, when I'm not logged in.
Edit: Nevermind, found the mistake.
There was missing a ' in get('guest_error', 'id').width = get('table', 'tag')[0].width
And now it works Thanks a bunch for the help | |
|
|
Nick Very Senior Member
Posts: 3,012 Status: Offline Gender: Male Location: vForums Age: 34 Joined:
pmwww | Re: Guests can't view profiles (26th Apr 10 at 4:33pm UTC) | | Aha, guess I shouldn't edit a forum's code using my iPod. >.< Got completely locked out, but have it fixed now since I got on my computer. and looks good. I may have some use for this code later on, depending if this forum falls through later. | |
|
Michael Moderator
Recoding the future Posts: 4,043 Status: Offline Gender: Male Location: UK Joined:
Additional Groups: Coding Team
pmvForum | Re: Guests can't view profiles (26th Apr 10 at 5:10pm UTC) | | Woops my bad... I added that line in and didn't test it... Glad it works.
| |
|