Copy changelogs
The Mini Ads Network & External Widget Distribution Engine (Poly Widgets for Perfex CRM - polywidgets) module transforms Perfex CRM into a powerful centralized advertising and widget management hub. It allows CRM administrators to create domain-locked marketing campaigns, customize 7 distinct interactive widget types, generate obfuscated single-file JavaScript pixel payloads (/widgets/pixel/{code}), and track real-time impression, click, and hover analytics across external websites via CORS telemetry APIs.
Core Features & Subsystems
1. Domain-Locked Campaign Management Engine
- Target Domain Locking: Restricts widget rendering strictly to authorized customer websites (
domainfield) to prevent unauthorized embedding. - Brand Identity Customization: Configures brand names and referral links across all campaign widgets.
2. 7 Interactive Widget Types Suite
- Information Bar: Announcement bar with headline text, CTA button, promo pill, and countdown timer.
- Information Card: Floating slide-in alert box with icon, title, description, and action link.
- Video Player Widget: Mini video player supporting YouTube, Vimeo, or HTML5 MP4 with autoplay, poster image, and CTA overlay.
- FlexiSupports Floating Hub: Multi-channel customer service widget supporting Zalo, Messenger, WhatsApp, Telegram, Phone call, Email, and Live chat with working hours control.
- Custom HTML Container: Flexible container for raw HTML/CSS/JS snippets.
- Lead Capture Popups: Modal form for lead generation and newsletter signup with AJAX logging.
- Gamified Spin Wheel: Interactive spin-to-win wheel & mystery gift box widget.
3. Obfuscated JS Pixel Engine & CORS Telemetry Analytics
- Single-File JS Obfuscator: Compiles and minifies campaign widgets into a single obfuscated JavaScript file (
/widgets/pixel/{code}). - Real-Time CORS Analytics: Collects daily impressions (
tblpolywidgets_impressions), clicks (tblpolywidgets_clicks), and hovers (tblpolywidgets_hovers) via CORS telemetry endpoints.
System Architecture & Data Flow
graph TD
A[Admin Configures Campaign & Widget in Perfex CRM] --> B[Generate Single-File Obfuscated JS Pixel Payload /widgets/pixel/code]
B --> C[External Website Embeds Single Script Tag]
C --> D[Script Executed on External Visitor Browser]
D --> E{Domain Verification Check}
E -->|Authorized Domain| F[Render Interactive Widget Layout on External Site]
E -->|Unauthorized Domain| G[Block Widget Rendering]
F --> H[CORS Telemetry API /widgets Records Impression Click Hover Analytics]