You could target admin-post.php to do the processing via the admin_post_$youraction hook:
This hook allows you to create custom handlers for your own custom GET and POST requests. The admin_post_ hook follows the format “admin_post_$youraction”, where $youraction is your GET or POST request’s ‘action’ parameter.
You can output the URL via admin_url( 'admin-post.php?action=add_foobar' ). Then hook your code:
add_action( 'admin_post_add_foobar', 'prefix_admin_add_foobar' );
function prefix_admin_add_foobar() {
// Handle request then generate response using echo or leaving PHP and using HTML
}
If you want to update things as you go, then probably AJAX is what you want, which works similarly to the above, with an action parameter that maps to an action hook.
Related Posts:
- InDesign to WordPress workflow
- Why doesn’t the WordPress Importer update posts?
- Some way to Flush or Overwrite all Imported Content in a Site for a Fresh Import – How?
- WordPress import does not fetch images, but just links them
- I am trying to match the wpallimport using the Xpath Filter
- Unable to activate wordpress importer after installing it
- Exporting and importing my WordPress database, but none of the plugin settings are importing
- Why Won’t Exported Blog From One Site Import Into New Site?
- Media is not attached after import
- Creating an online questionnaire form – by Importing the questions from a spreadsheet?
- WordPress Gutenberg react make import of __experimentalUseInnerBlocksProps which is no more experimetal
- CSV syntax for WP All Import upload without ACF
- WP ALL Import plugin – import data from certain ids
- How to export post 2 posts WordPress plugin data [closed]
- WP All Import – Execute Imports
- import posts with dutch/special letters
- WordPress plugin admin html being shown in Customizer iframe
- Permalinks stopped working after migration with WP all-in-one migration plugin
- WordPress and a secondary database?
- How to export all content with feature images?
- Import Instagram post to WordPress blog post
- WP.org acceptable iframe alternative
- Plugin generating unexpected output – on WP mysql dump import
- Attachments broken after giving WordPress its own directory
- WordPress does not allow me to upload a .xml file
- How to disable login in iframe which is hosted in same domain?
- Import Recent Posts Only and Ignore old ones if exist
- Save log for imports in WordPress database – options-table, custom post type or other place?
- Import a folder containing HTML files and images to WordPress
- Bulk Edit Media Library alt, caption, image names
- best way to upload a large file to wordpress using wp all import
- Add a WooCommerce Product Variant with attributes programmatically
- How to solve Blocked a frame with origin from accessing a cross origin frame error in wordpress?
- Import only new articles from Joomla to WordPress
- How to add plugin css and js to iframe
- Import tumblr post to wordpress blog
- phpBB 3 to bbPress
- iframe not showing on frontend when using a CMB2 field
- A way to upload old html pages with all its assets via WordPress admin and to add a fixed menu on top of those (a la Wayback Machine)
- How to export and import plugin data through WordPress tools option
- How to prevent WP All Export from wrapping XML nodes in CDATA? [closed]
- How to detect WP plugins used on a site
- Using WordPress as a CMS: Developer preferences for custom vs existing plugins
- Preserve custom URL parameter on more pages
- WordPress Capabilities: edit_user vs edit_users
- Passing .pem and .key files in cURL doesn’t work in WordPress
- Is there a limit on the size of a WP page?
- How to restrict Front-End Editor on a page?
- How do I create a custom wordpress slideshow plugin?
- Template plugin for blog posts? [closed]
- Skip file when plugin updated
- Are contributed plugin translations automatically installed in WordPress?
- Why would WP-CLI and WP Admin show different list of plugins with updates?
- Translating plugin inside the theme [closed]
- Admin Dashboard with Custom Tab for Client
- How to send little data between admin pages of my plugin?
- How to activate plugins for my WordPress sites from a remote server
- Register script in one plugin, and enqueue it in another
- how to load the language file in plugin?
- Getting a List of Categories for Use in a Plugin?
- UnWanted Custom field added in the wp page edit area
- How to get all of the activate_plugin action parameters?
- WP_Terms_List_Table Quick Edit not working
- Is there a directory my plugin can write files to that cannot be viewed via the browser/url?
- How to pass variables to a function argument using add_action [duplicate]
- Identifying where plugins are being used in your wordpress install
- How to get the particular product quantity in orders in Woocommerce [closed]
- Tutor LMS problem with Paid Memberships Pro [closed]
- Update WP option by plugin
- plugin enqueue style on all pages
- File Uploader – Upload without adding to Media Library
- Issue removing Media Editor Tabs — Duplicate Items
- A plugin popularity data inside “install new plugin” [closed]
- Error jQuery(domChunk).live is not a function
- I cannot include a file in my plugin settings page
- AJAX call inside plugin class is not getting to it’s response function
- Clicking custom plugin admin menu redirects to “No Update Required” on live site
- How to assign a specific service to a specific provider based on location
- The plugin generated 227 characters of unexpected output during activation. If you notice “headers already sent” messages
- How to add the google ad conversion tracking code into the thank you page
- How can I disable W3 Total Cache Image Lazy Load for Specific Post Type?
- How can I pull in the most recent blog posts to a section with Elementor Page Builder?
- How can I add a permissions callback to the REST API index pages?
- ERROR message: “The site is experiencing technical difficulties. Please check your site admin email inbox for instructions.”
- Installation failed, trying to install ANY plugin
- After form submission want to show success message in the form page
- Help Code Review – I need to write on .htaccess file from theme’s function.php
- Render Shortcode in Lightbox Gallery
- How to force regenerate thumbnails in WordPress posts?
- change product image url in widgets & shop page
- dummy category, include .php file
- Multiple Plugins Interacting with Menu
- Plugin constructor called multiple times
- how to call jQuery in admin as well as in homepage
- How to programmatically detect how many posts are displayed per page?
- Is a custom post type considred a plugin?
- Woocommerce disable checkout on specific day
- How to delete Password Protected posts cookies when a user logged out from the site
- wp_options Table keeps growing
- Run a function only once when logging into dashboard