User login page just reloads without going to favorites page

alexscj
Posts: 160
Joined: Mon Apr 01, 2013 3:04 pm

User login page just reloads without going to favorites page

Post by alexscj »

Hello,

I've noticed a strange error with the user login form on some of my sites ( "/action/login" page):

when pressing "Login" it just reloads the page (with the form fields cleared) and doesn't go to the "Favorites" page.

However if I manually go to "/action/favorites" page afterwards it shows the page fine, meaning it did login successfully.

Any idea what could be wrong? The forms used to worked properly. All sites (working
and not working) and are on the same server.

Older builds don't have this problem, such as Build 201306030701.
admin
Site Admin
Posts: 38004
Joined: Wed Sep 10, 2008 11:43 am

Re: User login page just reloads without going to favorites

Post by admin »

PM me url plz - i'll try to login
Don't forget to run script update
alexscj
Posts: 160
Joined: Mon Apr 01, 2013 3:04 pm

Re: User login page just reloads without going to favorites

Post by alexscj »

PM sent, thanks
admin
Site Admin
Posts: 38004
Joined: Wed Sep 10, 2008 11:43 am

Re: User login page just reloads without going to favorites

Post by admin »

Yes, sorry, the submit code was modified to return a surfer to the same page where he was before login assuming that login form was at index page for example.

Now I see it was a mistake.

There are 2 ways to fix it

1. run update and it will redirect to favorites as it was before

2. even w\o the update (and with the update ) you can add hidden field 'return_url' and script will redirect to that url in case of successful login.
Don't forget to run script update
alexscj
Posts: 160
Joined: Mon Apr 01, 2013 3:04 pm

Re: User login page just reloads without going to favorites

Post by alexscj »

Great, thanks a lot
admin
Site Admin
Posts: 38004
Joined: Wed Sep 10, 2008 11:43 am

Re: User login page just reloads without going to favorites

Post by admin »

NP
Thank you
Don't forget to run script update
alexscj
Posts: 160
Joined: Mon Apr 01, 2013 3:04 pm

Re: User login page just reloads without going to favorites

Post by alexscj »

On a side note, is there a way to make the login cookie last more than session?

Like keep the user logged-in until he opts to logout ?
admin
Site Admin
Posts: 38004
Joined: Wed Sep 10, 2008 11:43 am

Re: User login page just reloads without going to favorites

Post by admin »

The script uses php session to track users
So you can adjust php session lifetime as you need.
Don't forget to run script update
alexscj
Posts: 160
Joined: Mon Apr 01, 2013 3:04 pm

Re: User login page just reloads without going to favorites

Post by alexscj »

admin wrote:The script uses php session to track users
So you can adjust php session lifetime as you need.
Great, where/how can I adjust the php session lifetime ?
admin
Site Admin
Posts: 38004
Joined: Wed Sep 10, 2008 11:43 am

Re: User login page just reloads without going to favorites

Post by admin »

php.ini
session.* variavbles
Don't forget to run script update
Post Reply