ElementTest Pro 2.5.10
ElementTest Pro 2.5.10
WordPress.org Plugin Check (PCP) warning cleanup — resolves all 259 warnings from the 2026-07-09 scan, so the plugin now passes Plugin Check with zero errors and zero warnings.
Code fixes
- Removed the discouraged
load_plugin_textdomain()call; WordPress 4.6+ loads translations automatically for wp.org-hosted plugins. - Reordered
$_POST['page_url']sanitization in the conversion-tracking and variant-assignment AJAX handlers soesc_url_raw()directly wraps the unslashed input. - Prefixed the file-scope globals in
uninstall.php($elementtest_site_ids/$elementtest_site_id).
Documented false positives (justified phpcs annotations)
- Cross-function nonce verification in the AJAX handler (~110 warnings) — every handler verifies via
verify_admin_request()/verify_public_request()as its first statement. - Per-field unslash/sanitize loops for
$_POST['variants']/$_POST['goals']. WP_DEBUG-gatederror_log()calls.- Function-scoped variables in the
includes/views/templates (~127 warnings).
Internal
- JS
VERSIONconstant inassets/js/frontend.jssynced to 2.5.10.
Verification
php -lpasses on all edited files.- PHPCS (WPCS 3.x) with the exact sniff set from the Plugin Check report shows zero issues.