Skip to content
Snippets Groups Projects
Commit 3d38b99c authored by Grzegorz Rola's avatar Grzegorz Rola
Browse files

Added notice dismiss link.

parent 78725a25
No related branches found
No related tags found
1 merge request!15Feature/notice dismiss link
Pipeline #10110 failed
......@@ -81,13 +81,16 @@ class AjaxHandler implements HookablePluginDependant
*/
public function processAjaxNoticeDismiss()
{
error_log(print_r($_POST,true));
if (isset($_POST[self::POST_FIELD_NOTICE_NAME])) {
$noticeName = $_POST[self::POST_FIELD_NOTICE_NAME];
if (isset($_POST[self::POST_FIELD_SOURCE])) {
$source = $_POST[ self::POST_FIELD_SOURCE ];
} else {
$source = null;
}
update_option(
PermanentDismissibleNotice::OPTION_NAME_PREFIX . $noticeName,
PermanentDismissibleNotice::OPTION_VALUE_DISMISSED
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment