Opened 3 years ago
Closed 3 years ago
#8505 closed enhancement (fixed)
Add php fallback for dismissing sitewide notices.
Reported by: | dcavins | Owned by: | dcavins |
---|---|---|---|
Milestone: | 9.0.0 | Priority: | normal |
Severity: | normal | Version: | 8.0.0 |
Component: | Messages | Keywords: | has-patch commit |
Cc: |
Description
Dismissal of sitewide notices is currently handled via JavaScript in both the Legacy and Nouveau template packs, and there is no php fallback. @imath has suggested that a fallback would be a good improvement.
Additionally, there is no centralized function to handle the change to the user's closed_notices
meta, so the logic is repeated in several places in our code base.
Attachments (2)
Change History (5)
Note: See
TracTickets for help on using
tickets.
bp_messages_dismiss_sitewide_notice()
as centralized function to dismiss a notice for a user. * Watch for requests to{user_profile}/messages/notices/dismiss
. * Introducebp_get_message_notice_dismiss_link()
to generate nonced link to the dismiss action URI. * Use new URI for dismissal link in Legacy and Nouveau sitewide notice templates (replacing JS-only button dismissal). * Update Legacy CSS for dismissal link. Nouveau looks OK.