Notifications Manager
Overview
The Admin Notifications Manager provides comprehensive control over the user notification system. Administrators can view all notifications across the platform, send system-wide announcements, monitor notification statistics, and manage notification delivery to specific user segments.
Key capabilities include:
- View all user notifications in a timeline format
- Send system-wide or targeted notifications
- Filter notifications by type, priority, and read status
- View notification statistics and read rates
- Delete individual or bulk notifications
- Preview notification details in a modal
System Requirements
PHP Requirements
PHP Extensions Required
mysqli- Database connectivityjson- JSON encoding for metadata and AJAX responsessession- Session management for CSRF protection
PHP Settings
session.autostart = Off
date.timezone = Your/Timezone
Features & UI Elements
Page Header
[Screenshot: notifications-header]
The page header displays:
- Title: "Notifications Manager"
- Breadcrumb: Dashboard / Notifications
Alert Messages
Success and error messages appear below the header:
- Success (green): "Notification sent to X user(s)"
- Error (red): "Invalid security token" or "No target users found"
Statistics Cards
[Screenshot: notifications-stats]
Four statistics cards show notification overview:
Notifications by Type
[Screenshot: notifications-by-type]
A grid of clickable type cards showing:
- Icon - Visual representation of notification type
- Type Name - comment, like, follow, subscription, etc.
- Count - Total notifications of this type
- Read Rate - Percentage of notifications read
Click a type card to filter the timeline by that type.
Send Notification Form
[Screenshot: notifications-send-form]
A form to send new system notifications:
Notification Types
Priority Levels
Target Audience Options
Notifications Timeline
[Screenshot: notifications-timeline]
The main timeline shows all notifications with:
Timeline Header:
- Title and icon
- Filter buttons: All, Unread, Urgent, High
Each Notification Item:
- Icon - Color-coded by notification type
- Username - Recipient user
- Timestamp - When notification was created
- Title - Notification headline
- Message - Content preview (150 chars)
- Badges - Type, priority, and "NEW" for unread
- Delete Button - Remove the notification
Unread Indicator:
- Yellow background with left border
- "NEW" badge displayed
Click Action:
- Click a notification to open the detail modal
Notification Detail Modal
[Screenshot: notifications-detail-modal]
When clicking a notification, a modal shows:
Pagination
- 20 notifications per page
- Previous/Next navigation
- Page number links
- Maintains filter parameters across pages
Step-by-Step Usage
Sending a System-Wide Notification
- Navigate to Admin Panel → Users → Notifications
- Scroll to the Send System Notification form
- Enter a Title (e.g., "System Maintenance Notice")
- Enter a Message with details
- Select Type: System
- Select Priority: Normal (or higher if urgent)
- Leave Icon as default or enter custom class
- Optionally add Action URL for more info
- Select Target Audience: All Active Users
- Click Send Notification
Sending to Specific Users
- Open the Send System Notification form
- Fill in Title and Message
- Select Target Audience: Specific Users
- A new field appears for User IDs
- Enter comma-separated user IDs:
1, 5, 23, 45 - Click Send Notification
Sending to Subscribers Only
- Open the Send System Notification form
- Fill in Title and Message
- Select Type: Subscription
- Select Priority: High (to emphasize importance)
- Select Target Audience: Active Subscribers Only
- Click Send Notification
Filtering Notifications
By Type:
- Click a type card in the "Notifications by Type" section
- Timeline filters to show only that type
- URL updates with
?type=commentparameter
By Status:
- Click filter buttons in the timeline header:
- All - Show all notifications
- Unread - Only unread notifications
- Urgent - Priority = urgent
- High - Priority = high
Viewing Notification Details
- Click any notification in the timeline
- Modal opens with full details
- View all fields including metadata
- Click Close or press ESC to dismiss
- Click outside the modal to close
Deleting Notifications
Single Notification:
- Find the notification in the timeline
- Click the trash icon button
- Confirm the deletion
- Notification is soft-deleted (isdeleted = 1)
Best Practices
Notification Content
- Titles:
- Keep under 50 characters
- Start with action word (e.g., "New", "Update", "Action Required")
- Be specific about the notification purpose
- Messages:
- Keep under 200 characters for preview
- Include essential information first
- Provide context for the action
- Action URLs:
- Always use relative paths (e.g.,
/settings/profile.php) - Ensure the linked page is accessible to the user
- Don't link to admin-only pages for regular users
Priority Guidelines
Target Audience Selection
- All Users: Major announcements, terms updates, system-wide changes
- Subscribers: Subscription-specific news, premium features
- Creators: Creator program updates, payout notifications
- Specific Users: Individual issues, support follow-ups
Troubleshooting
Common Issues
"No target users found"
Cause: Selected audience has no matching users
Solutions:
Check if there are active subscribers (for Subscribers Only)Check if there are verified creators (for Creators Only)Verify user IDs exist (for Specific Users)
- Check accountstatus = 'active' in tblCMSUsers
Notification Not Appearing
Cause: Notification was soft-deleted or not created
Solutions:
- Check tblUserNotifications for the record
- Verify isdeleted = 0
- Check userid matches the target user
- Verify createdat is recent
Modal Not Opening
Cause: JavaScript error or overlay issue
Solutions:
- Check browser console for JavaScript errors
- Ensure Font Awesome is loaded
- Clear browser cache and reload
- Check for CSS conflicts
Filter Not Working
Cause: URL parameter issue
Solutions:
- Check URL contains correct parameters
- Verify SQL query is using parameters
- Check for special characters in filter values
Database Issues
Table Does Not Exist
Cause: Migration not run
Solutions:
- Run the CREATE TABLE statements from Installation Requirements
- Verify foreign key references (tblCMSUsers must exist)
Foreign Key Constraint Error
Cause: Referenced user doesn't exist
Solutions:
- Check userid exists in tblCMSUsers
- Verify user hasn't been deleted
- Use valid user IDs when sending to specific users
Translatable Strings
{
"notificationstitle": "Notifications Manager",
"notificationsbreadcrumb": "Dashboard / Notifications",
"notificationstotal": "Total Notifications",
"notificationsunread": "Unread",
"notificationslast24h": "Last 24 Hours",
"notificationslast7d": "Last 7 Days",
"notificationssendtitle": "Send System Notification",
"notificationsformtitle": "Title",
"notificationsformmessage": "Message",
"notificationsformtype": "Type",
"notificationsformpriority": "Priority",
"notificationsformicon": "Icon (Font Awesome class)",
"notificationsformactionurl": "Action URL (optional)",
"notificationsformtarget": "Target Audience",
"notificationsformuserids": "User IDs (comma-separated)",
"notificationsformsend": "Send Notification",
"notificationstimelinetitle": "Notification Timeline",
"notificationsfilterall": "All",
"notificationsfilterunread": "Unread",
"notificationsfilterurgent": "Urgent",
"notificationsfilterhigh": "High",
"notificationsdetailtitle": "Notification Details",
"notificationsdetailuser": "User",
"notificationsdetailtype": "Type",
"notificationsdetailpriority": "Priority",
"notificationsdetailmessage": "Message",
"notificationsdetailaction": "Action URL",
"notificationsdetailstatus": "Status",
"notificationsdetailcreated": "Created",
"notificationsdetailmetadata": "Metadata",
"notificationsstatusread": "Read",
"notificationsstatusunread": "Unread",
"notificationsempty": "No notifications found",
"notificationsemptyfiltered": "No notifications matching your filters",
"notificationssuccesssent": "Notification sent to {count} user(s)",
"notificationserrorcsrf": "Invalid security token",
"notificationserrorrequired": "Title and message are required",
"notificationserrornousers": "No target users found",
"notificationserrordelete": "Failed to delete notification",
"notificationsconfirmdelete": "Delete this notification?",
"notificationstargetall": "All Active Users",
"notificationstargetsubscribers": "Active Subscribers Only",
"notificationstargetcreators": "Verified Creators Only",
"notificationstargetspecific": "Specific Users (comma-separated IDs)",
"notificationstypecomment": "Comment",
"notificationstypelike": "Like",
"notificationstypefollow": "Follow",
"notificationstypesubscription": "Subscription",
"notificationstypepayment": "Payment",
"notificationstypesystem": "System",
"notificationstypemessage": "Message",
"notificationstypecontent": "Content",
"notificationsprioritylow": "Low",
"notificationsprioritynormal": "Normal",
"notificationspriorityhigh": "High",
"notificationspriorityurgent": "Urgent"
}
Related Documentation
- User Management - User account management
- Email Templates - Email notification templates
- Creator Profiles - Creator verification
- User Subscriptions - Subscription management