Previous Thread
Next Thread
Print Thread
Hop To
#174516 01/19/2007 6:39 PM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

I like the option to collapse forums (I have no business in the Threads 6.x Discussion, having never used it for instance), and it appears a cookie is set so those forums are still collapsed the next time we visit. It just doesn't seem to always stay that way, tho...

(Can't delete this post any more to "move" it)



Last edited by jgeoff; 01/19/2007 6:46 PM.

GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #174544 01/19/2007 9:17 PM
Joined: Jun 2006
Posts: 3,837
I
Ian Offline
Carpal Tunnel
Carpal Tunnel
I Offline
Joined: Jun 2006
Posts: 3,837
we used to have favourite forums - which I think is what you are after smile

Ian #174994 01/22/2007 1:53 PM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

Okay, I'm confirming that collapsed forums don't stay collapsed. This is due to the cookie expiring the same day it's being set, unlike the others which expire in September. Any way we can expand that? wink


GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #174997 01/22/2007 2:26 PM
Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Hmm, that's odd. My javascript may be a bit off, but it's supposed to not expire for a year. This is the bit of javascript that controls that:

Code
expires = 365 * 60 * 60 * 24;
var expires_date = new Date( today.getTime() + (expires) );
document.cookie = id + "=" +escape( value ) + ";expires=" + expires_date.toGMTString()  + ";path=/";

I'll need to tinker with that and see if maybe I'm doing something wrong.

Rick #174998 01/22/2007 2:32 PM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

Here, I'm sharing my cookie with you. wink
All my other non-session ubbcentral cookies expired in September 2007

Name: ubbt_collapsed
Content: null%7Ccat5%7C
Host: www.ubbcentral.com
Path: /
Send For: Any type of connection
Expires: Monday, January 22, 2007 9:38:22 PM



GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #175000 01/22/2007 2:57 PM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

Rick - I've been trying to look up details on this, and it seems some take a different root. For example:
Code
//creating expiration date

var now = new Date();

now.setTime(now.getTime() + 1000 * 60 * 60 * 24 * 365)

document.cookie = "name=" + escape(phrase) + ";expires=" + now;


Notice the 1000 (milliseconds) in there. (I've seen some examples with and without the 1000 ms, so I don't know...)

Full explanation here



GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #175002 01/22/2007 3:20 PM
Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Thanks. Will need to turn on cookie debugging and test on my devel box and see if that works.

Rick #175857 01/28/2007 3:28 AM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

Ever solve this issue? Collapsed Forums cookies just expire daily, as opposed to everything else...



GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #176499 02/01/2007 4:39 AM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

Still a (minor, but present) issue in b5...




GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #178377 02/13/2007 3:16 PM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

I hate bumping so much, but is this still on a to-do list somewhere? whistle wink

OR - where is the code where I can play around with it myself to see what the solution is?


GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #178378 02/13/2007 3:39 PM
Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Yep, it's still on the todo list. The javascript that sets the cookie is in the ubb_jslib.js file. Still need to tinker around with this. Haven't forgotten, it just kinda keeps getting pushed down a bit wink

Rick #178381 02/13/2007 4:09 PM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1
Originally Posted by Rick
Yep, it's still on the todo list. The javascript that sets the cookie is in the ubb_jslib.js file.

Just played with it, expiring my cookies many times, and it seems that it works properly if you change Line 256

From:
Code
	expires = 365 * 60 * 60 * 24;
To:
Code
	expires = 1000 * 365 * 60 * 60 * 24;
(added the 1000 ms as described above)

cool


GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #178506 02/16/2007 3:14 AM
Joined: Aug 2006
Posts: 1,649
Likes: 1
Pooh-Bah
Pooh-Bah
Joined: Aug 2006
Posts: 1,649
Likes: 1

Damn, a mere 7 characters (including spaces) to fix it... maybe for 7.2... :/

But, at least the fix is above for those who want to implement it! wink



GangsterBB.NET (Ver. 7.6.1.1)
PHP Version 5.6.40 / MySQL 5.7.23-23 (was 5.6.41-84.1) / Apache 2.4.54
2007 Content Rulez Contest - Hon Mention
UBB.classic 6.7.2 - RIP
jgeoff #178519 02/16/2007 12:12 PM
Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Dangit, I meant to squeeze that in for 7.1. I may still be able to wink

Rick #178531 02/16/2007 5:41 PM
Joined: Jun 2006
Posts: 16,292
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,292
Likes: 116
And here I got off my butt and upgraded my main site already wink


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Gizmo #178571 02/17/2007 7:03 AM
Joined: Jun 2006
Posts: 3,837
I
Ian Offline
Carpal Tunnel
Carpal Tunnel
I Offline
Joined: Jun 2006
Posts: 3,837
Is this the only change required? smile

jgeoff #180994 03/19/2007 6:00 PM
Joined: Jun 2006
Posts: 16,292
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,292
Likes: 116
This will be fixed in 7.1.1, see discussion here


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Gizmo #181063 03/20/2007 10:39 AM
Joined: Aug 2006
Posts: 111
member
member
Joined: Aug 2006
Posts: 111
I just opened my 7.1 file and it is in there with the 1000...

Fred #181152 03/20/2007 5:42 PM
Joined: Jun 2006
Posts: 16,292
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,292
Likes: 116
Odd, because my 7.1 file isn't and i downloaded it fresh over last weekend...


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Gizmo #181203 03/21/2007 9:23 AM
Joined: Aug 2006
Posts: 111
member
member
Joined: Aug 2006
Posts: 111
Hmm, strange because I didn't add it. I downloaded it on Saturday morning/afternoon, around 10am EST I believe.

Yeah, looking at the dates it looks like Rick said this (getting the change into 7.1) on 3/16 and I downloaded it on 3/17.

Rick, FYI, you forgot the space after 1000. Not that it makes a difference functionally, but it isn't as pretty. tongue

Fred


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
spam issues
by ECNet - 03/19/2024 11:45 PM
Looking for a forum
by azr - 03/15/2024 11:26 PM
Editing Links in Post
by Outdoorking - 03/15/2024 9:31 AM
Question on barkrowler and the like
by Mors - 02/29/2024 6:51 PM
Member Permissions Help
by domspeak - 02/27/2024 6:31 PM
Who's Online Now
3 members (rootman, Gizmo, Nightcrawler), 562 guests, and 186 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20230217)