XF 2.1 Dismissed notice cookie is set for how long?

bzcomputers

Well-known member
Trying to figure out dismissed notice cookie durations...

1) Is it currently set with the same durations as the session cookie or is it separate?
2) Does selecting "remember me" on login have any affect on its' duration?
3) What are the cookie/duration differences between logged in member and a guest?
4) As far as I can tell there is no current option to make any adjustments to the dismissed notice cookie duration. Is this true?
 
Once a notice is dismissed, it will remain dismissed until the member selects the option to restore dismissed notices, which will restore all active dismissed notices.

1562772587392.webp
 
Once a notice is dismissed, it will remain dismissed until the member selects the option to restore dismissed notices, which will restore all active dismissed notices.

View attachment 206167
I don't think OP is talking about notice system notices.

Cookie notices are hardcoded i believe which admins can not reconfigure.

Last time i checked/played with it during 2.0 it was having no dismiss duration. Once you close the browser and reopen it will show up again. No idea if any changes happened with 2.1.
 
As above, notices that are dismissed by members are dismissed permanently and stored in the database until either the notice is reset or the user itself restores them.

Notices that are dismissed by guests have a cookie set. This is set for a period of one month. There are no options to adjust the duration.
 
As above, notices that are dismissed by members are dismissed permanently and stored in the database until either the notice is reset or the user itself restores them.

Notices that are dismissed by guests have a cookie set. This is set for a period of one month. There are no options to adjust the duration.

Will editing the notice, for example changing the message text, and then re-saving the notice invalidate a cookie set for that notice? Or is the cookie set on something that requires deleting the entire notice and creating a new one to clear the cookie?
 
As above, notices that are dismissed by members are dismissed permanently and stored in the database until either the notice is reset or the user itself restores them.

Notices that are dismissed by guests have a cookie set. This is set for a period of one month. There are no options to adjust the duration.
Where is the user prefs restore notices option these days? I cannot see it in my preferences, and yes I do have valid dismissed notices.
 
Notices that are dismissed by guests have a cookie set. This is set for a period of one month. There are no options to adjust the duration.
Unfortunately once a guest has dismissed the notice, there is no way to reset it. You would have to create an entirely new notice.

Is this still the case for guest notices @Chris D (one month, no way to adjust the duration, and no way to reset it)?
 
Is this still the case for guest notices @Chris D (one month, no way to adjust the duration, and no way to reset it)?

Correct, for guests there is still no way to reset or adjust duration.

It is now possible to reset a notice for members using the "Reset" button, but it will still not reset the notice for guests. For guests you would need to recreate a completely new notice, which in my opinion makes the reset button not very useful in most circumstances.

1698728993174.webp
 
Unfortunately, it doesn't look like this works for guests :(
You are correct. I just looked at the code and all it does is delete the member's records from the notice_dismissed table for a specific notice. It does nothing to the cookie set for guests. So, I'm pretty sure the add-on doesn't do anything more than using the reset button on the edit notice page, other than automate the clicking of it once a week and it's limited to applying towards a single notice.
 
You are correct. I just looked at the code and all it does is delete the member's records from the notice_dismissed table for a specific notice. It does nothing to the cookie set for guests. So, I'm pretty sure the add-on doesn't do anything more than using the reset button on the edit notice page, other than automate the clicking of it once a week and it's limited to applying towards a single notice.

That's what I found as well. I haven't had time to look into it, but I'd be surprised if there wasn't a way to modify the expiration of the cookie. Since the cookie stores the notice ID as the value, it seems like it'd be possible to even set different expiration lengths for different notices.

1699025252771.webp

May be something @Ozzy47 could look into adding to Notices Plus.
 
Top Bottom