

Admin settings panel - Basic configuration
Init Chat Engine is a clean and minimal frontend chatbox plugin, designed for homepage or site-wide communication with comprehensive administrative controls.
This plugin is the core user system behind the Init Plugin Suite – optimized for frontend-first interaction, extensibility, and real-time gamification.
GitHub repository: https://github.com/brokensmile2103/init-chat-engine
Key Features:
Frontend Experience:
– Built with 100% REST API and Vanilla JS
– No jQuery, no bloat – blazing fast
– Fully embeddable via [init_chatbox] shortcode
– Multiple chat rooms via [init_chatbox room="..."] – each room has its own messages, pinned message and limits
– Guest messaging support (optional)
– Smart polling system (adaptive 3.5–10s based on activity, up to 20s when the chatbox is scrolled out of view)
– Browser notifications when new messages arrive
– Scroll-up to load history, scroll-down to auto-scroll
– Optimistic sending & “new message” jump button
– Clean UI with customizable themes
– Template override supported (chatbox.php)
Administrative Control:
– Complete Settings Panel – Basic, Security, and Advanced configurations
– Message Management – Search, view, delete messages with pagination
– User Moderation – Ban/unban users by IP or user ID with expiration
– Rate Limiting – Prevent spam with configurable message limits
– Word Filtering – Block messages containing prohibited words
– Statistics Dashboard – View chat activity, user engagement, and trends
– Cleanup Tools – Automatic and manual cleanup of old messages
– Custom CSS Support – Full styling customization options
Security & Moderation:
– IP-based and user-based banning system
– Configurable rate limiting (messages per minute)
– Word filtering with custom blocked word lists
– Message moderation queue (optional)
– Automatic cleanup of old messages and expired bans
– Admin override capabilities
Multilingual Ready:
– Translation-ready with full .pot file included
– Vietnamese translation included
– Easy to translate to any language
Perfect for community-based sites, forums, fanpages, manga readers, SaaS dashboards, customer support, or any interactive chat widget.
Shortcode [init_chatbox] supports the following attributes:
height – Set chat height (e.g., height="400px")width – Set chat width (e.g., width="100%")theme – Apply custom theme (e.g., theme="dark")show_avatars – Override avatar setting (true/false)show_timestamps – Override timestamp setting (true/false)title – Add custom chat titleclass – Add custom CSS classesid – Set custom container IDroom – Chat room name (letters, numbers, - and _). Leave empty for the default room (the main chat, which keeps all existing messages). Each room has its own messages, pinned message and message limit (e.g. room="vip")allow_guests – Per-room override of the “Allow guests” setting (yes/no)max_messages – Per-room override of the “Maximum Messages” setting (10–10,000)Example: [init_chatbox height="500px" title="Community Chat" theme="modern"]
Room example: [init_chatbox room="members" title="Members Lounge" allow_guests="no" max_messages="500"]
Only one chatbox per page is supported. Room overrides (allow_guests, max_messages) are saved when the shortcode is displayed on published content (not in drafts or previews), so use the same attributes everywhere a room is embedded.
Shortcode [init_chat_stats] also accepts room to show statistics for a single room (e.g. [init_chat_stats room="vip"]); without it, all rooms are counted.
This plugin provides filters and actions to allow developers to extend word filtering, message processing, and chat behavior without modifying core files.
init_plugin_suite_chat_engine_word_filter_strategy
Modify word filtering strategy (substring, word, regex).
Applies to: Message validation
Params: string $strategy, array $settings, string $message
init_plugin_suite_chat_engine_blocked_words
Modify the blocked-words list before validation.
Applies to: Message validation
Params: array $blocked_words, array $settings, string $message
init_plugin_suite_chat_engine_bypass_filter
Bypass filtering under custom conditions (VIP, internal users, etc.).
Applies to: Message validation
Params: bool $bypass, string $message, WP_User|null $user, array $settings
init_plugin_suite_chat_engine_word_block_hit (action)
Triggered when a word filter rule blocks a message.
Applies to: Message validation
Params: string $blocked_word, string $message, string $strategy
init_plugin_suite_chat_engine_enrich_message_row
Extend chat message data (add flags, metadata, user info, etc.).
Applies to: Backend DB JSON output
Params: array $message_row, WP_User|null $user
init_plugin_suite_chat_engine_message_saved (action)
Fired after a message is stored.
Applies to: POST /send
Params: int $message_id, string $message, int|null $user_id, string $display_name, string $room (added in 1.3.9; '' = default room)
init_plugin_suite_chat_engine_ip_headers
Choose which $_SERVER keys are trusted (in priority order) when detecting the visitor IP used for bans and rate limiting. Default keeps the existing list (Cloudflare / proxy headers first, then REMOTE_ADDR). Sites not behind a proxy or CDN can return array( 'REMOTE_ADDR' ) to prevent spoofed X-Forwarded-For headers from bypassing IP bans.
Applies to: Ban check, rate limiting, message logging
Params: array $ip_keys
This plugin is licensed under the GPLv2 or later.
You are free to use, modify, and distribute it under the same license.