An AJAX request to your server is no different to any other PHP request the server might handle, e.g. the frontend.
Browser requests have a time and memory limit configured at the server level, WordPress itself is not responsible for setting or enforcing those limits.
Say if am importing something big using ajax how can perform that without effecting the server with a memory limit of 250MB?
You have the following options:
- Use less memory
- Don’t process the entire import in a single request
- Break your import file into smaller chunks that get processed separately
- Do the processing elsewhere, e.g. a CLI task. PHP running from a CLI command has no upper limit on time or memory except the amount of physical memory installed on the server.
Otherwise, you can’t do stuff for free, there is always a cost. Browser requests are not suited to long running expensive/heavy tasks.
Related Posts:
- Ajax action has 200 status but response of No response data available for this request
- ajaxurl not defined on front end
- Why does WordPress add 0 (zero) to an Ajax response?
- Saving data-URI to media library
- Nonces can be reused multiple times? Bug / Security issue?
- How can I run AJAX on a button click event?
- How-to implement admin Ajax inside an admin WP_List_Table?
- Empty POST data on server on AJAX request using Angular $http
- Using AJAX in FrontEnd with WordPress Plugin Boilerplate (wppb.io)
- wp_localize_script $handle
- How to enable users to down-vote in this simple voting counter (that uses the post meta)?
- Adding callback function for wp_ajax_ has no effect
- get all products of one category
- Get returned variable from a function to add_shortcode function
- Plugin Settings not Saving on Ajax re-ordered table
- Using Ajax call in jQuery doesn’t work in widget
- Timeout on Admin-Ajax?
- Admin-ajax.php appending a status code to ajax response
- Comment `Reply` link doesn’t work if comments are loaded from ajax
- Ajax in WordPress – path issue
- WordPress Ajax callback function from plugin – OOP
- Ensure function has completed before allowing another Ajax call
- Frontend Ajax call not working using wp_ajax, wp_enqueue_script and wp_localize_script
- Fetching the value of forms in WordPress AJAX
- include wp-blog-header not working on MAMP
- Any problem in using native jquery ajax style instead of using admin-ajax.php?
- Show special field when correct shipping is chosen
- .mo translation strings not loading in PHP scripts that handle AJAX calls
- How can I pass get_the_author_meta(‘user_email’) through the REST API?
- Woocommerce checkout update totals with datepicker
- Including the necessary functions for a custom ajax registration form
- How to localize admin.php only once
- get post attachment using ajax
- Dashboard – get status and position of metaboxes and pass them to ajax method
- Create a new post using rest api and save featured image using an external image url
- how to search users by ajax live search
- wp.template() returns tags in Ajax response
- How to get Metabox custom field to show checked if value is updated using post meta query?
- Fatal error: Uncaught Error: Call to undefined function get_option()
- Use just a shortcode from another page
- template_redirect or admin-ajax.php?
- how to get context information inside my funcion
- AJAX form post returns 0
- Update Data parameter of a wp_localize_script() call
- jquery & ajax sending data to php
- Can’t get AJAX call working in custom plugin
- Bad Request in AJAX
- 400 Bad Request, in wordpress theme development, wp_ajax
- ajax recursive calls on wordpress returning answers outsite the function scope
- Ajax submit result opens in admin-ajax.php
- Are there any security risks when submitting data-attribute data through AJAX?
- insert query on a custom table using ajax with jQuery plugin Jeditable
- Plugin AJAX Save to Custom Table
- Data not insert and update through ajax and jQuery in admin page?
- Setting a JSON web token from a secondary api as a secure cookie on WordPress
- WP ajax requests not stacking?
- AJAX button with success callback. (Titan Framework)
- AJAX call returns ‘testtest0’ instead of ‘test’ – why?
- Best practice for plugin: always detect admin-ajax call?
- add_action wp_ajax_ not loading in plugin file WP Network
- Why is the form not updating when I select a new sector from the list?
- Plugin Form Submitting to admin-ajax.php instead of admin-post.php
- Ajax +wordpress onClick link redirect to new page and create html content
- AJAX request not routing through proxy
- Get cat parameter from admin-ajax
- WordPress (pagenow link) in ajaxurl change after i change plugin language
- Ajax on the Administration Side of plugin – returns 0
- Jquery php request is returning a weird result
- Error code when migrate
- Posts form with AJAX request – Plugin development
- GET request return value as error instead of success
- Forbidden Error in ajax call with wordpress
- “add to cart” links css class “ajax_add_to_cart” doesn’t show in woocommerce in widget sidebar
- ajax stopped working when not logged in wordpress
- ajax call return 406 not acceptable for non logged users only
- Does $this context change in an AJAX callback?
- ajax response strips multidimensional array and unable to decode
- WordPress Ajax not returning Response
- Using AJAX to submit and return data inside the WordPress Plugin Boiler Plate framework
- Performing ajax request in wordpress
- Inserted data from database does not showing on front-page without referesh page?
- wp_ajax function return the html page
- $_SESSION inside php function executed by AJAX
- Two same AJAX calls – one is working, other doesn’t
- Using JavaScript in WordPress page to call for server data using AJAX
- How to get values from Tinymce visual editor popup?
- How To do Ajax In WordPress Custom Plugin?
- Ajax call not working with
- Array/List Edit in Backend
- WP Ajax on page load not working on bluehost but was working on Godaddy
- Ajax not working to insert, query and result data
- WP Cron as Fast as WordPress AJAX?
- Can’t get query string in ajax call
- Ajax url value to pass ‘variable’ to use in query
- Ajax functions – no access to wp-admin.php only online
- An adiitional function fires on my AJAX submit
- Fatal error: Call to a member function query() on a non-object in my ajaxpage
- Trigger a JavaScript function based on the data fetched from Woo commerce hook
- Why my admin-ajax url returns 0 even after adding echo and die() at the end of function?
- WordPress plugin boilerplate AJAX functionality