I'm using a plugin that utilizing admin-ajax to $_POST save data as cookie. All working fine except each fetch not fast enough to complete.
So, I'm trying to replace admin-ajax to use custom admin-ajax (To gain more speed and reduce load)
Custom admin-ajax is ready and loaded. But not posting data to work. Can anyone help?
You shouldn't do that. It still needs to load most of WordPress. What I propose is switching to REST API endpoint, it is faster because it doesn't load admin scripts. Here are benchmarks: https://deliciousbrains.com/comparing-wordpress-rest-api-performance-admin-ajax-php/
I saw this post before I decided to get into custom admin ajax. Custom admin ajax will be much faster and maybe can better control what to load?
The plugin is only for posting drop down time and date selection purpose, can it not be using the most minimum / does it need to load everything in original admin-ajax?
If you are happy to check the demo site, please send me your email and will email you the admin details. Thanks.
If response has nothing to do with WP, you can change it, however that script should be placed outside WordPress directory, otherwise it might create problems in the long run.
You can email me to the address on my profile page.
Email sent. Have you received?
Yes. Since this request doesn't touch WordPress this can be done. However, I can't do this for a few hours because I need to go outside. Also, this looks like a minor thing that is not used that much, maybe I am wrong.
Please don't take long. Also, other users may already complete the task. Thank you.