Some useful tips regarding working with AJAX in WordPress.
When working with Ajax in WordPress, I believe that there’s at least one thing we can do to make development and maintenance easier.
One purpose of this blog is to provide articles for others who are getting started in WordPress development. Case in point: Ajax in WordPress.
Only a preview post. Will get to the real one later.
Incorporating Ajax in WordPress can be done in both procedural programming and in object-oriented programming. Here’s how to do it via object-orientation.
Same as above. The continuation actually.
Let’s say that you’re working with Ajax in WordPress. And let’s say that, whatever you’re building, is using object-oriented programming. Depending on the complexity of your work, you may find that how you’ve implemented your Ajax functionality doesn’t work. That is: – You’ve implemented the proper hooks – You’ve got the callbacks defined – You’re `echo`ing the data properly – You’ve got the `wp_die()` call at the end of each request – And you’ve setup `console.log()` or other debugging statements in your Development environment But you’re still seeing the request return `0` for everything you’ve implemented. What gives?