Developers
English
WordPress Plugin
Listeo Admin - Quick Featured / Verified Toggles for Listings: Developer Guide
Developer guide for safe admin-column toggle customizations around Listeo featured and verified listing metadata.
Developer scope. This documentation is based on the requested product behavior. The plugin source was not present in the current workspace, so verify exact action names against the plugin package before extending it.
Expected data model
Quick featured and verified workflows normally update Listeo listing metadata. Keep custom code aligned with the theme's expected values.
| Meta key | Expected purpose |
|---|---|
_featured | Featured listing flag used by Listeo queries, badges, or sorting. |
_verified | Verified listing flag used by Listeo badges and trust indicators. |
Safe implementation rules
- Only expose toggles to users with an appropriate admin capability.
- Use nonces for every toggle request.
- Sanitize listing IDs with
absint(). - Confirm the post type is
listingbefore writing meta. - Return structured JSON from AJAX handlers.
- Do not change license, update, or entitlement logic.
Recommended extension pattern
If you need custom behavior after a toggle, add it in a small compatibility plugin rather than editing the product files. Typical additions include audit logs, cache clearing, admin notices, CRM sync, or package validation before allowing featured status.
Audit examples
| Event | Recommended audit data |
|---|---|
| Featured enabled | Listing ID, admin user ID, timestamp, previous value, new value, reason if available. |
| Verified enabled | Listing ID, reviewer user ID, verification evidence reference, timestamp. |
| Status removed | Listing ID, user ID, timestamp, reason. |
Regression checklist
- Toggle works from the admin list screen without page corruption.
- Unauthorized users cannot toggle either status.
- Public badges update after cache clear.
- Featured sorting and package rules still behave correctly.
- Verified status is not confused with user-level verification.