Thanks for replying. My forums don't require registration. Sometimes, people who have registered may want to post anonymously. So, I have used a link that allows people to log out and returns them back, so they can post under any name.
But, once they are logged out, as they continue to look around, they may want to reply to a post with their username. So, I'd like to have a link that takes them to a log-in form, and then redirects them back to the post they were at.
you are done with the code changes. now place [high]$logincode[/high] in your footer. when the user will login, it will be redirected to the exact same location.
that should do it.
PS. there is no need to say: "pleaseeeeeee helppppppp". people will help you here. just post your thread and be patient. some freaky guy(girl) will answer to you.
1. create 2 new templates called 'home_logoutcode' and 'home_logincode'.
2. in the code above, replace the 'forumhome_logoutcode' with 'home_logoutcode' and 'forumhome_logincode' with 'home_logincode'.
3. replace $logincode with $homelogincode
4. edit your template content the way you want.
btw, it doesnt make sense what you want to do. the login code is there, all you have to do is enter the username and password, when you are logged out. why do you want to add a link? when the user can enter his info right there? explain to me.
get inspired from the 'forumhome_logincode' with the code (for example) and edit it to say what ever you want.
You are THE MAN! I agree, it doesn't make sense, but here's the problem:
if a registered user is at a public computer, he can enter a forum without having to log-in {all my forums allow registered & unregistered to post}. So, once he's in there, if he clicks to reply, it gives him a reply form with fields, the fields say, Username: "Unregistered", and Password:, with nothing nothing for the password.
If a registered user puts in his real username & password in these fields, it kicks him out, and tells him he doesn't have access to that page.
So, if you are a registered user, and you go into a forum without logging in, it won't take you username and password at the posting form. Why? I have no clue. But, you can try. I will pm you a reg. username & password. Go into any forum, except the second one.
I really wish it would work, because then people could go in and out of being anonymous easliy. So, this was the only workaround I could think of.
so? all he have to do is enter the name and pass. it's working perfectly. i tried 2 ways. first i posted as anonymous and it posted fine. then i replyed to the thread and entered this time the pass you gave me. it worked perfectly also. look here: http://www.tealit.com/forum/showthre...=&threadid=196
... Don't post anonymously first. Just go into a forum, click on a thread to reply to. Put in the reg username and password at the posting form. Please clear your cookies before you begin.