|
Cookie question
|
| Skeeve |
Posted on 17-09-2011 18:10
|

Member

Posts: 70
Joined: 02/08/2008
|
This isn't one of those "I can't login" or "I keep getting logged out" threads.
I've looked in Search but there are quite a lot of cookie threads.
My issue is the length of time a member is logged in. Before the upgrade, I could login to my site and stay logged in for a week, and all my New Posts worked just fine. Every Monday or so, I'd have to actually click Login and New Posts worked fine.
But since upgrading, I have to login multiple times a day if I leave the site, and New Posts aren't highlighted like they should be.
I seem to remember a couple years ago that I set the length of the cookie expiration somewhere. I think. Or am I misremembering I did?
It's a pain to have to look at the post date/time to figure out if I've read a thread or not.
Thanks.
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| PolarFox |
Posted on 17-09-2011 21:22
|

Admin

Posts: 1480
Joined: 26/08/2008
|
And your version now?
|
| |
|
|
| Skeeve |
Posted on 17-09-2011 23:17
|

Member

Posts: 70
Joined: 02/08/2008
|
7.02.03
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| PolarFox |
Posted on 18-09-2011 11:13
|

Admin

Posts: 1480
Joined: 26/08/2008
|
Maybe something wrong with time on your server/PC?
Is there any errors in admin->errors?
|
| |
|
|
| Skeeve |
Posted on 28-09-2011 14:26
|

Member

Posts: 70
Joined: 02/08/2008
|
Let me rephrase my problem. I want to login and stay logged in until I actually click Logout.
It was set this way before I upgraded to the latest version. Also, my "new posts since last visit" isn't working correctly. When I log in, the new post indicator icons are showing no new posts, yet looking at the post times, I can see there are new posts.
Merged on Dec 24 2011 at 21:02:41:
Is it still considered bumping if I wait 3 months?
I still have this cookie issue.
Edited by Skeeve on 25-12-2011 03:02
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| PolarFox |
Posted on 25-12-2011 18:29
|

Admin

Posts: 1480
Joined: 26/08/2008
|
Problem with date/time on your/server side?
|
| |
|
|
| Skeeve |
Posted on 25-12-2011 20:01
|

Member

Posts: 70
Joined: 02/08/2008
|
No, everything is correct. It started with the last core update. 7.02.03
I have to login each day, I'm assuming the cookie is set to 12 hours, because I can come back during the day and be logged in, but longer than that and I have to login again. Once I do log in, Threads Since Last Visit doesn't show previous posts. It only works after I have logged in and someone posts afterwards.
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| Ankur |
Posted on 26-12-2011 06:09
|

Admin

Posts: 1291
Joined: 02/11/2010
|
Try looking it in the function includes\classes\Authenticate.class.php :
function setUserCookie($userID, $salt, $algo, $remember = false, $userCookie = true)
May be you will get some idea from there
|
| |
|
|
| Skeeve |
Posted on 26-12-2011 11:50
|

Member

Posts: 70
Joined: 02/08/2008
|
Code// Set User Cookie
public static function setUserCookie($userID, $salt, $algo, $remember = false, $userCookie = true) {
global $_COOKIE;
$cookiePath = COOKIE_PATH; $cookieName = COOKIE_USER;
if ($remember) {
$cookieExpiration = time() + 1209600; // 14 days
} else {
$cookieExpiration = time() + 172800; // 48 hours
}
if (!$userCookie) {
$cookiePath = COOKIE_PATH."administration/";
$cookieName = COOKIE_ADMIN;
$cookieExpiration = time() + 3600; // 1 hour
Here?
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| Rush_ |
Posted on 26-12-2011 20:36
|

Junior Member

Posts: 22
Joined: 12/01/2011
|
Code if ($remember) {
$cookieExpiration = time() + 60*60*24*365; // one year if u want)
} else {
$cookieExpiration = time() + 172800; // 48 hours
}
just use remember checkbox to stay logged in for a long time. |
| |
|
|
| Skeeve |
Posted on 26-12-2011 21:44
|

Member

Posts: 70
Joined: 02/08/2008
|
thanks, i'll try that
Merged on Dec 28 2011 at 08:33:32:
Didn't help, I still have to login every morning. I always check "Remember Me". Even here, I've had to login every day I visit. 
Merged on Dec 30 2011 at 08:02:26:
OK, I'll try Google. I was really hoping for some support here, I've always gotten it in the past.
When I find the answer, I'll come back and post it here so you can help the next person.
smh
Merged on Jan 02 2012 at 09:10:22:
UPDATE:
So, turns out it wasn't the cookies after all.
The User Info Panel has a problem. I remembered that when I updated, I also switched back to the basic User Info Panel. Once I re-enabled the Enhanced User Info Panel and got rid of the basic version, my cookies started working correctly.
I'll assume something within the code defining the "Remember Me" is screwed up...?
Merged on Jan 16 2012 at 07:58:58:
Apparently I was mistaken. After changing the User Info panel, I was on my site quite a bit and stayed logged in. As soon as I let a day go by, I was being logged out again.
Why isn't Remember Me working?
On a side note, I have bragged about php-fusion since I first started using it, but lately the cms support has been lacking and I'm not so inclined to recommend it to others. Have you lost members who would always step up and try to find solutions to these issues or has interest in helping others waned?
Edited by Skeeve on 16-01-2012 13:58
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| miskith |
Posted on 16-01-2012 15:05
|

Member

Posts: 119
Joined: 28/07/2010
|
I don't know, if PHP-Fusion is using session_set_cookie_params(), but i think it isn't. And you are using SESSION? SESSION without these params has expiration time to the first browser shutdown (I don't know, how it's called in English, but in Czech it's "Na konci relace"->"At the end of session").
|
| |
|
|
| Skeeve |
Posted on 16-01-2012 17:12
|

Member

Posts: 70
Joined: 02/08/2008
|
I don't know. I only know that Remember Me doesn't work at my site, this site and Craigs site.
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| miskith |
Posted on 16-01-2012 17:26
|

Member

Posts: 119
Joined: 28/07/2010
|
Oh, "remember me" isn't working on this site for you? Then, check into your browser settings, if you have enabled deleting cookie(s) after browser shutdown.
|
| |
|
|
| Skeeve |
Posted on 16-01-2012 19:30
|

Member

Posts: 70
Joined: 02/08/2008
|
Remember me works on every site I visit, except for php-fusion sites.
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|
|
| miskith |
Posted on 16-01-2012 20:33
|

Member

Posts: 119
Joined: 28/07/2010
|
Has your browser any cookie(s) manager? If so, could you look at expiration time after singin?
|
| |
|
|
| Skeeve |
Posted on 17-01-2012 04:27
|

Member

Posts: 70
Joined: 02/08/2008
|
I just logged in and left the site. Here are my cookies:




Merged on May 13 2013 at 21:39:28:
This is still an issue. And it only affects php-fusion sites I visit.
Edited by Skeeve on 14-05-2013 03:39
"The world is my country, and do good is my religion." - Thomas Paine
|
| |
|