Fixes and additions from six GitHub issues: snippet code keeps its backslashes, full backups finish on hosts that cut long requests off, code snippets can be edited and deleted, a clear-cache tool, and protected, self-cleaning filesystem backups.
- New: Edit and delete Elementor Pro code snippets (#197).
update-code-snippetchanges a snippet's code, title, location, priority, status or jQuery option, only the fields you send.delete-code-snippetmoves it to the trash, or deletes it permanently withpermanentandconfirm. Both can be undone from History, and the undo brings a snippet back with its status and options.delete-code-snippetships switched off. - New:
clear-cache(#201). Clears Elementor's CSS files and the page caches a site uses: WP Rocket, LiteSpeed Cache, W3 Total Cache, WP Super Cache, WP Fastest Cache, Autoptimize, Breeze, SiteGround Speed Optimizer, WP-Optimize, Cache Enabler and Kinsta, with a result for each (purged, queued, skipped or failed).add-code-snippet,update-code-snippet,add-custom-cssandadd-custom-jstakeclear_cache: trueto clear caches after saving. Each plugin was checked against its own code; Kinsta has no public API, so EMCP calls the purge its own MCP plugin uses, which is not yet verified on a live Kinsta site. - New in Pro:
get-backup-statusanddelete-backup(#199, #200).get-backup-statusreports a backup's progress and size, and moves a running backup forward on each call.delete-backupremoves a backup and its files, including failed ones and ones stuck at running; it ships switched off. Pages and media already had delete tools:delete-postmoves a page to the trash and can be undone, anddelete-mediaships switched off. - New: Filesystem backups are protected and cleaned up (#196). The copies Write File, Edit File and Delete File take before a change moved from
uploads/emcp-fs-backupsto a folder inwp-contentwith a name derived from the site's keys, each copy ends in.bak, and deny files cover Apache and IIS, so a copy of a PHP file can no longer be downloaded or run on servers that ignore.htaccess, such as nginx and Caddy. Copies older than 30 days are removed daily (days and a size limit are set under History > File backups, where copies can also be selected and deleted).list-fs-backupslists them andpurge-fs-backups(switched off) removes old or named ones and names the History entries that lose their undo. Existing copies move over automatically, and their History undo keeps working. The security scan now checks this folder for downloadable copies. - Changed (Pro): Full backups continue in the background (#200).
create-backupused to build the whole backup in one request, which hosts such as Kinsta cut off with a 502, leaving a backup stuck at "running" and 0 B. It now works for a few seconds and returns; a larger backup comes back as running and continues through WP-Cron and through eachget-backup-statuscall, each answering well inside the Gateway's 30 second limit.wait: truekeeps the old behaviour for WP-CLI. Backups a host cut off earlier are now marked failed, so they can be told apart and deleted. Checked live with a 2.9 GB full backup. - Fixed: Backslashes were removed from code saved with
add-code-snippet(#198). WordPress unslashes post meta on save, so regex escapes,\nin strings and escaped quotes were lost without an error. Code is now stored exactly as sent and read back; a snippet whose code does not match is saved as a draft and reported. The same fix covers custom fields fromcreate-postandupdate-post, ACF field values, SEO titles and descriptions in the Rank Math, Yoast, SEOPress, The SEO Framework, SureRank, Slim SEO and Visibility integrations. - Fixed: Undoing a deleted post brought it back as a draft. WordPress untrashes posts as drafts; undo from History now restores the status the post had, published included. Undoing a permanent delete also keeps meta that save hooks rewrite during the restore (Elementor Pro snippets lost their jQuery option).
- Fixed: Saving a code snippet from code cleared its jQuery option. Elementor Pro rebuilds a snippet's options from its admin form on every save, so saves without the form (MCP tools, History undo, trash and restore) emptied them. EMCP now keeps the option through those saves.
- Changed (Pro): The migration connector is 1.4.1: it never places a filesystem backup folder from an archive.