I found the answer – this contains sample code which helped me resolve the issue.
Related Posts:
- How to add/retrieve the post trash link?
- How does nonce verification work?
- How to expire a nonce?
- Fatal error: Call to undefined function wp_create_nonce()
- Using nonce external of WP Admin
- Nonce best practices: hidden input vs. wp_localize_script?
- “The link you followed has expired” when previewing a post
- wp_verify_nonce keeps failing
- Handling nonce generation in AJAX registration process
- increase nonce lifespan
- wp_verify_nonce() via REST always returns false
- Nonce failing in IE
- my theme breaks WP export
- Why am I getting a 403 from check_admin_referer()?
- x-wp-nonce across domains
- wp_create_nonce doesn’t verify when using WP_List_Table
- Handling expired nonces
- What is really “wp_nonce_field” and how does it work? [duplicate]
- Cannot verify nonce
- wp_verify_nonce return false despite correct parameter passed
- WordPress JSON API nonces and Vue development server
- Verify a nonce in Form submission
- phpcs error in WordPress
- Stop WordPress nonces expiring
- Several nonces?
- Nonce keeps failing
- Public posts – preventing duplicate form submissions
- How to obtain “wp_rest” nonce for WP Statistics plugin manually?
- WordPress “nonce” message
- CSP nonces with Cloudflare Workers
- Why are nonces working in Firefox but not in Chrome?
- wp_verfy_nonce keeps giving false
- Nonce – reissue with ajax poll
- wp_nonce_url generating invalid links
- How to insert wp_nonce field within echoed string
- Nonce check causing issues when creating new post
- Weird nonce validation problem
- Logout button in menu without “wp” in links
- Check nonce in the new bulk_edit_posts action
- How do I programatically empty trash?
- Turn Off Automatic Trash Deletion?
- Is it safe to assume that a nonce may be validated more than once?
- Should nonce be sanitized?
- Using Nonces for AJAX that only retrieves data
- trash_post action with Custom Post Type
- WordPress failure when logging out
- Ajax function returns -1
- How to hook in to bulk trash posts
- WordPress has a trash for users? (Wrong result for count_user, greater than expected)
- Restrict access to the Trash folder in Posts
- How to change redirect after moving a page to trash?
- wp_verify_nonce always returns false when logged in as admin
- Error after deleting Custom Post Type with a function (no trash used)
- Dynamically create/remove terms in taxonomy when custom post type is published/trashed
- AJAX requests broken due to HTTPS for wp-admin
- Restore trashed posts with comments
- wp_nonce_url to users.php for deleting user not working
- Deleted pages showing up when querying for child pages
- Security checking in meta_box save is reluctant?
- How to check an ajax nonce in PHP
- wp_verify_nonce not working
- how to send Ajax request in wordpress backend
- Shortcode to delete post from front end
- WP Admin AJAX Security – using POST to include a relative URL
- wp_create_nonce() in REST API makes user->ID zero
- wp_create_nonce function doesn’t work inside a plugin?
- Nonce failing on form submission
- Found 2 elements with non-unique id (#_ajax_nonce) and (#_wpnonce)
- Why ajax doesn’t work on certain wordpress hooks?
- Custom login doesn’t work properly
- Is there value in using a wp_nonce for POST requests?
- Missing ‘Move to Trash’ option from bulk select box
- wp_nonce_field displaying twice
- Is it safe to use a global wp nonce per user instead of a nonce per action?
- Rest API: wp_verify_nonce() fails despite receiving correct nonce value
- How to restore all items from trash
- Backbone with custom rest endpoints
- Restrict Access without Creating Users
- How to use nonce
- Re-use Nonce in Repeating Event Signup Buttons
- Script doesn’t trash custom post types. Instead it duplicates the post and generate new versions in the trash
- How to add a WordPress Nonce for this form to avoid CSRF
- How to change ‘Move to Trash’ to ‘Move to Draft’ for my blog’s users?
- Reliable way to add nonce to HTTP Header in WordPress?
- wp_nonce vs jwt
- wp_verify_nonce not working on the mobile device
- How to not cache nonces with WP Rocket?
- whether a nonce is required for get type and get_query_var?
- Unable to update plugins or log out
- Does it make sense to check a nonce on user log in?
- Override plugin function to show invoices even if not logged in
- CSRF attack to create USER
- WordPress deletes custom posts instead of trash them
- Is it necessary to use a WordPress nonce when allowing users to download public data?
- Wp doesn’t save meta box data
- wp_trash_post not firing as expected (also applies to trashed_post)
- Saving metabox updates causing fatal error
- How to prevent users from permanently deleting a post from trash, but allow them to restore it?
- wp_verify_nonce is always false even when the nonces are identical
- Is there a solution to expired nonces in forms when using full page caching that doesn’t involve configuring the cache?