Contents
Social Proof Popups — Plugixa Testimonial
Small notification popups on the frontend showing recent testimonials — e.g., “Jane from NYC gave 5 stars 2h ago”. Fully configurable timing, position, and styling.
How it works
- A
SocialProofPHP class hooks intowp_footeron every frontend page. - JS fetches recent approved testimonials from
GET /frontend/social-proof. - Popups cycle according to your configured timing (initial delay → show for N seconds → wait for M seconds → next).
- Users can dismiss with a click or the close button.
- Assets (CSS + JS) are loaded only when the feature is enabled in settings.
Enabling
Go to Plugixa Testimonial → Settings → Social Proof.
| Setting | Key | Default | Notes |
|---|---|---|---|
| Enable social proof | sp_enabled |
false |
Master toggle. When off, no assets are loaded. |
| Position | sp_position |
bottom-left |
bottom-left or bottom-right. |
| Display duration | sp_display_duration |
5 |
Seconds each popup stays visible (1–30). |
| Delay between | sp_delay_between |
10 |
Seconds between popups (1–60). |
| Initial delay | sp_initial_delay |
5 |
Seconds before the first popup (0–60). |
| Max popups | sp_max_popups |
5 |
Stop after N popups (1–20). |
| Show photo | sp_show_photo |
true |
Show photo or initials avatar. |
| Show rating | sp_show_rating |
true |
Show star rating. |
| Show time ago | sp_show_time_ago |
true |
Show relative time (“2h ago”). |
| Min rating | sp_min_rating |
1 |
Only show testimonials with rating ≥ N (1–5). |
| Background color | sp_bg_color |
#ffffff |
Popup background. |
| Text color | sp_text_color |
#1d2327 |
Popup text. |
| Border color | sp_border_color |
#e0e0e0 |
Popup border. |
| Hide on mobile | sp_hide_on_mobile |
false |
Hide popups on screens ≤480px. |
What a popup shows
By default, each popup contains:
- Photo or initials — circular avatar.
- Client name — bold.
- Company / location — smaller, below the name (if available).
- Rating — star icons.
- Testimonial snippet — first ~80 characters.
- Time ago — “2h ago”, “yesterday”, “3 days ago”.
- Close button — small X icon.
The popup slides in from the configured corner with a CSS transition, waits for sp_display_duration seconds, then fades out.
Queue behavior
On page load:
- Wait
sp_initial_delayseconds. - Fetch recent testimonials (up to
sp_max_popups). - Show the first popup.
- Wait
sp_display_duration+sp_delay_betweenseconds. - Show the next.
- Repeat until the queue is exhausted.
After sp_max_popups popups have been shown, no more appear on that page load. Reloading the page restarts the queue.
User dismissal
Each popup can be dismissed in three ways:
- Click anywhere on the popup — closes immediately.
- Close button (X) — closes without counting as “clicked.”
- Auto-dismiss — after
sp_display_durationseconds.
Dismissal advances the queue to the next popup.
Asset loading
Social-proof assets load independently from the shortcode assets:
social-proof.css+social-proof.jsload on every frontend page whensp_enabledis true.- They do not load in the admin or on pages without any frontend HTML (e.g., AJAX-only endpoints).
This differs from testimonial shortcode assets, which only load on pages that contain a shortcode (unless load_assets_globally is enabled).
REST endpoint
The JS fetches testimonials from:
GET /wp-json/plugixatestimonial/v1/frontend/social-proof
Public, no authentication required. Respects the sp_min_rating filter and returns at most sp_max_popups items.
Response:
[
{
"id": 42,
"client_name": "Jane Doe",
"client_company": "Acme Inc",
"client_role": "CEO",
"rating": 5,
"client_photo_url": "https://.../photo.jpg",
"created_at": "2026-04-15T10:30:00"
}
]
Multilingual
On multilingual sites, the social proof endpoint filters by the current site language (detected via WPML/Polylang). A French page shows French-language testimonials.
Theming
The popup uses CSS custom properties that pick up the color settings:
.pxt-sp-popup {
--pxt-sp-bg: var(--sp-bg, #ffffff);
--pxt-sp-text: var(--sp-text, #1d2327);
--pxt-sp-border: var(--sp-border, #e0e0e0);
}
Override in Settings → General → Custom CSS or your theme’s stylesheet:
.pxt-sp-popup {
--pxt-sp-bg: #1e1e1e;
--pxt-sp-text: #fff;
--pxt-sp-border: #333;
box-shadow: 0 10px 40px rgba(0, 0, 0, .3);
}
Privacy considerations
- Social proof popups display client names and photos from approved testimonials.
- Ensure you have consent to display testimonials publicly (covered by the approval workflow — the status
approvedis explicit publication). - The plugin does not track dismissal events or personal visitor data.
Hooks
| Hook | Type | Description |
|---|---|---|
plugixatestimonial_social_proof_enabled |
filter | Override the enabled state. |
plugixatestimonial_social_proof_query_args |
filter | Modify the REST query args. |
plugixatestimonial_social_proof_testimonials |
filter | Modify the returned testimonials array. |
plugixatestimonial_social_proof_popup_html |
filter | Customize the rendered popup HTML (JS-side, via a registered hook). |
Troubleshooting
No popups appearing
- Check
sp_enabledis on in Settings. - Check browser console for network errors on
/frontend/social-proof. - Verify approved testimonials exist — empty DB = empty queue.
- If
sp_min_ratingis high, testimonials below that threshold are excluded.
Popups appear but photos are broken
- The testimonial’s
client_photo_idpoints to a non-existent attachment. Edit the testimonial and re-upload. - Initials fallback should render anyway — check CSS conflicts.
Popups slide in too fast / too slow
Adjust sp_display_duration and sp_delay_between in settings. Default 5s display + 10s delay = one popup every 15s (reasonable for most sites).
Position conflicts with another plugin
If another plugin (chat widget, cookie banner) uses the same corner, set sp_position to the opposite corner.
For finer control, override the CSS:
.pxt-sp-container {
bottom: 100px; /* lift above the chat widget */
left: 20px;
}
Related
- Settings → Social Proof — Social Proof tab
- Testimonials Management
- Hooks Reference