The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Link to Automatic logout

3 posters

Go down

Solved Link to Automatic logout

Post by Mr. Eddster March 14th 2013, 9:12 pm

With my new navbar, it wont let me automatically logout.
When users click this link, it goes to a page that asks you to log out... i dont want that. i just want it to automatically log out when you click on this link
There has to be a http:// link for this, right?
ALSO: When users use the toolbar logout, it goes to that "are you sure you want to log out" page. If its possible to add CSS to make it so that when users click on the toolbar logout link it automatically logs out that'd be fantastic
Here's a pic of what i mean:

Link to Automatic logout Sfb10

Please help!


Last edited by Mr. Eddster on March 22nd 2013, 6:45 pm; edited 1 time in total
Mr. Eddster
Mr. Eddster
Forumember

Male Posts : 382
Reputation : 7
Language : English

http://sports-forumbuzz.canadian-forum.com/

Back to top Go down

Solved Re: Link to Automatic logout

Post by LGforum March 15th 2013, 12:00 am

In order to log you out when you first click that link, the session is ID must be in the query string of the link. Aka '&tid=blablabla'
If that isn't there then it will need confirming. Presumably you've used a custom logout link, and so it doesn't contain the unique session ID.
The correct logout link is in the default navbar (navbar not toolbar), so you'd have to use JavaScript in order to move it or grab the URL.
LGforum
LGforum
Hyperactive

Male Posts : 2265
Reputation : 264
Language : English
Location : UK

Back to top Go down

Solved Re: Link to Automatic logout

Post by Mr. Eddster March 15th 2013, 1:20 am

LGforum wrote:In order to log you out when you first click that link, the session is ID must be in the query string of the link. Aka '&tid=blablabla'
If that isn't there then it will need confirming. Presumably you've used a custom logout link, and so it doesn't contain the unique session ID.
The correct logout link is in the default navbar (navbar not toolbar), so you'd have to use JavaScript in order to move it or grab the URL.
i have a new navbar, dropdown bar. it isnt a default navbar. When I used the default/user generated navbar, i would click on "logout" and it would automatically log me out. That is all i want...

Edit: Found the link like u said, it works now, thanks!
BUT, Is there a way so that when people use the toolbar logout it automatically logs them out as well? Is there a way i can edit that, or put in some CSS?
DOUBLE EDIT: Well now it doesnt work... Confused Mad u said i need to add some javascript to make sure it keeps working? What is that javascript?
It automatically logged me out twice then it stopped working
Mr. Eddster
Mr. Eddster
Forumember

Male Posts : 382
Reputation : 7
Language : English

http://sports-forumbuzz.canadian-forum.com/

Back to top Go down

Solved Re: Link to Automatic logout

Post by LGforum March 15th 2013, 9:55 pm

No you don't need to add any JavaScript for the link in the default Forumotion navbar to work. Look at the links. The logout link in the default navbar contains this: '&tid=longstringofnumbers'
That part is unique and what is needed to automatically log the user out. That part is what is missing from the toolbar link and any custom logout links.

So you'd need JavaScript to make any custom links contain that vital information, because if it doesn't then you'll be taken to the confirm page.
LGforum
LGforum
Hyperactive

Male Posts : 2265
Reputation : 264
Language : English
Location : UK

Back to top Go down

Solved Re: Link to Automatic logout

Post by Mr. Eddster March 15th 2013, 11:37 pm

LGforum wrote:No you don't need to add any JavaScript for the link in the default Forumotion navbar to work. Look at the links. The logout link in the default navbar contains this: '&tid=longstringofnumbers'
That part is unique and what is needed to automatically log the user out. That part is what is missing from the toolbar link and any custom logout links.

So you'd need JavaScript to make any custom links contain that vital information, because if it doesn't then you'll be taken to the confirm page.
exactly. I copy and pasted that &tid= stuff, and it DID work twice. Then it didnt work. I dont know why it stopped working.
I went to admin panel=>Display=>Headers & Nav=>Login. Then i went down to secondary redirection url, and copied that down.
Here's the url that was in that box: /login?logout=1&tid=add4cd12bdcd1eedce220dbaad8a40aa&key=90d1fc


Then I went to my Templates=>overall_header, and inserted that link where it should've gone. Published the template.
Then i went and clicked on the link, and it logged me out, as it should
logged back in
then i tried to log out again, and it didnt work
Went and checked the link again, and it has changed
i dont fully understand what you are trying to tell me. All i want is for whenever someone clicks on that logout link, that it logs them out EVERY TIME, without the confirmation.
How do I get it to do that???
Mr. Eddster
Mr. Eddster
Forumember

Male Posts : 382
Reputation : 7
Language : English

http://sports-forumbuzz.canadian-forum.com/

Back to top Go down

Solved Re: Link to Automatic logout

Post by LGforum March 18th 2013, 1:14 am

That's what in saying. You can't unless you find a way to have that unique link. It is unique to your user and unique to only that session. It is randomly generated in order to identify your session and your session only. It will change every time and will be different for every user every time. Seeing the issue? There is no permanent link you can copy and paste to automatically log you out.

Now you've seen the issue first hand. The link is always changing. So you'd need to use JavaScript in order to MOVE the unique link into a new place, because you can not hard code one in the templates.
LGforum
LGforum
Hyperactive

Male Posts : 2265
Reputation : 264
Language : English
Location : UK

Back to top Go down

Solved Re: Link to Automatic logout

Post by Mr. Eddster March 22nd 2013, 6:44 pm

ya i wont worry about it. too much code to add. its not really a problem just something that would've been nice.
this is solved i guess
Mr. Eddster
Mr. Eddster
Forumember

Male Posts : 382
Reputation : 7
Language : English

http://sports-forumbuzz.canadian-forum.com/

Back to top Go down

Solved Re: Link to Automatic logout

Post by SLGray March 22nd 2013, 10:51 pm

Topic Solved & Locked


Link to Automatic logout Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51453
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum