Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save champsupertramp/109245a08c07d658cf40 to your computer and use it in GitHub Desktop.
Save champsupertramp/109245a08c07d658cf40 to your computer and use it in GitHub Desktop.
Ultimate Member Notification extension - Add a custom notification
<?php
/**
* Ultimate Member Notification extension - Add a custom notification
*/
if( class_exists("UM_Notifications_API") ){
global $um_notifications;
$um_notifications->api->store_notification( $author, 'my_custom_notification_type', $vars );
add_filter("um_notifications_core_log_types","custom_um_notifications_core_log_types",10,1);
function um_notifications_core_log_types( $array ){
$array['my_custom_notification_type'] = array(
'title' => __('You won the internet Today!','um-notifications'),
'template' => 'You have just got <strong>90000</strong> from <strong>Vegetta</strong>',
'account_desc' => __('When I receive points balance from another member','um-notifications'),
);
return $array;
}
}
?>
@sagarwalzade
Copy link

Hi,

I have used Real-time Notifications extension of ultimate members plugin.

I want to raise a custom notification when admin submit a post from backend. but i am not able to get that output.

Can you please help me how to implement it with the help of this code i found in their documentation : https://docs.ultimatemember.com/article/53-using-notifications-api-to-add-custom-notifications

I will wait for your response, please message me as early as possible.

Thanks.
Sagar W.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment