Hi I am working on my first plugin, and its going really well except for a small issue. i am trying to use $wpdb to modify the plugins data but because i am calling it with ajax, the class is not instantiated.
after major google searches i figure i need to include wp-blog-header.php which makes sense however, i can’t load it and keep receiving this error:
Warning: include(/wp/wp-blog-header.php) [function.include]: failed to open stream: No such file or directory in C:\xampp\htdocs\wordpress\wp\wp-content\plugins\automatik\products_ajax.php on line 6
is there some trick to including it? please trust me its not a path issue.
since the ajax is simply adding/editing database content, i am considering whether it might be better just use a separate class for this functionality rather than load all the wordpress backbone for a couple of queries. any feedback or thoughts on this are also very much appreciated.
- The topic ‘Problem with plugin because i am using ajax’ is closed to new replies.