Ajax - The core of WordPress uses Ajax only in the administration screens. For instance, Ajax is used for instant updates when you are doing comment moderation, and when you are adding and deleting items from lists such as categories, blogroll, and posts; Ajax is also the technology behind the ...
0
votes
2answers
649 views
How to filter a static post page with ajax and $wp_query
I'm at a loss, I've found several unanswered questions related to this one. I have a static post page which has a search form in the sidebar. What I want to happen is to type in a keyword and then ...
5
votes
2answers
4k views
Enable Submit Comment Without Page Reload (Using Ajax)?
When user writes a comment and hits the submit button, WordPress reloads the page, before the comment is shown to the user.
Is there an Ajax-based solution that allows users to submit questions ...
1
vote
1answer
112 views
making sense of admin-ajax
So I'm working with ThemeTrust's "reveal" theme, and there is an ajaxed in chunk-of-content that I'm really trying to change (grab custom meta fields (images) + insert into a slideshow). As far as I ...
0
votes
2answers
432 views
Specify ABSPATH in jQuery url
I'm building a custom jQuery form and I need to specify the siteurl in the url that loads /wp-admin/admin-ajax.php.
I place this code in the template that has the form:
<script ...
3
votes
2answers
1k views
Why might a plugin's 'do_shortcode' not work in an AJAX request?
tl;dr: Contact Form 7's shortcode doesn't work in an AJAX request when called with do_shortcode
functions.php
add_action('wp_ajax_ps_get_survey_form', 'ps_get_survey_form');
...
0
votes
1answer
721 views
How to make wordpress URLS google friendly for ajax driven sites?
Our wordpress site utilizes the wordpress cms to serve up json data that we ingest via ajax requests and serve up with javascript. I would like to create URLs for my regular wordpress pages/posts that ...
1
vote
1answer
212 views
Plugin Settings not Saving on Ajax re-ordered table
This is an extension of Update Option Stored in Multi-Dimensional Array which was help getting draggable plugin options to save via ajax (which works), but unfortunately this is specific to the actual ...
1
vote
2answers
2k views
How to load wp_editor() through AJAX/jQuery
I have a theme that is custom developed and really complex. One of the things that I have is multiple content areas where users can specify content for specific tabs. I load multiple instances of ...
1
vote
0answers
249 views
I want to load post content by categories using Ajax
I have question.
I would like to load post content, custom post, depends on category.
So first of all I would like to have drop down menu which will list all my categories then once user will select ...
0
votes
1answer
420 views
what does $options = get_option('test_theme'); do?
I'm trying to set up theme options so they save with AJAX, I found this tutorial http://return-true.com/2010/01/using-ajax-in-your-wordpress-theme-admin/
it's calling
$options = ...
3
votes
1answer
433 views
How to add a sub menu with AJAX?
What i want to do is fire up the add_submenu_page() function from within ajax on my plugin options page.
When i click an "Add League" link, i want to display an ajax input[text] that will save into ...
0
votes
2answers
308 views
Connect Agile Carousel to WordPress AJAX
Originally I hacked together Agile Carousel and WordPress by passing wp-load.php into the AJAX script but clearly that isn't the way to go. I've now read that wp-admin/admin-ajax.php is better, but I ...
0
votes
1answer
513 views
Ajax function not returning any results
Im trying to create an ajax call when I click a link, the link is the post thumbnail, and the result should show the post content.
When I use admin-ajax.php it works fine, but the problem then is ...
0
votes
2answers
194 views
Wordpress Front-End Theme Editor
I would like to change my option panel to the front-end.
So user can see whats happening with the site.
Changes must be real-time.
Searched allover but cant find a way to solve this.
10
votes
2answers
652 views
How to cache json with wp-super cache
In a new project we are using wp-super-cache (the client's preferred plugin) to create the static html files for custom content types. But we are trying to figure out if everything is being cached ...
6
votes
3answers
3k views
What is the simplest ajax upload plugin or script to be used with wordpress?
I'm trying to use image upload in my theme's options page and haven't found yet a simple ajax upload script with many tutorials or a good documentation, I just want a simple straightforward script so ...
1
vote
1answer
234 views
Adding wp_ajax to a theme outside functions.php (on specific template page)
I'm doing a function which requires the use of the wp_ajax action.
I've followed this guide to set it up with the differences of adding the requesting the object AJAX file in functions.php and also ...
0
votes
2answers
259 views
include wp-blog-header not working on MAMP
To clarify my question...
My plugin is/was using AJAX to call the file pluginname/submit/pick.php My pluginname/pluginname.php contains the usual plugin header and wordpress automatically finds it.
...
5
votes
2answers
460 views
Ajax in a settings page (update_option is undefined)
I'm making a request to my plugin's php file via ajax and it's supposed to save some data with update_option(), but php throws an error:
Call to undefined function update_option()
I'm guessing that ...
0
votes
1answer
820 views
Change Query Arguments (filter) with jQuery/Ajax or PHP?
I have a pretty complex wordpress-site for travelling. There's an "archive-hotels.php", a template for the custom-post-type "Hotels". Inside the CPT is a taxonomy called "City", so we can do this: ...
0
votes
1answer
309 views
wpquery via ajax
I can reload my page and have php write a new wpquery and replace the content on my page, but I really don't want to deal with a new page load. Is there an easy way to send a wpquery string (eg "p=7") ...
0
votes
1answer
134 views
Parsing post->ID in included plugin file
running into something that has got me completely puzzled.
I have a plugin with a main file that looks like this:
// Global Variables
$mouldings_prefix = 'mouldings_';
$mouldings_name = 'Mouldings';
...
0
votes
1answer
693 views
Register Template
I created a register template for Wordpress with some ajax so that users can click on the register link in my header and the register form opens up in a lightbox. For some reason on submit, if there ...
0
votes
1answer
244 views
How to make image in TinyMCE clickable
I'm trying to use the tinyMCE in the Wordpress front end and not using wp_editor() because I need the editor to be created through Ajax (something that a wp_editor can't handle as far as I know).
...
-1
votes
1answer
245 views
How to add a hash tag to the menu URLs? [closed]
I currently use AJAX in my theme to load the main content. I want the menu to be highlighted on the current page.
The script I'm using for AJAX puts a "#" in the URL .. (ex: http://localhost/#/bio/)
...
9
votes
3answers
764 views
Load minimum WordPress environment
I made my own upload service for my website that is separate from WP, but uses WP to provide low level db functions and user verification. To do that, I include wp-load.php in my main script ...
0
votes
2answers
231 views
Why plugin ajax response is -1?
I do not know why this response me -1 always? I am using this code in my plugin file.
i want response on click p tag
<?php function myajax(){ ?>
<script type="text/javascript">
...
0
votes
1answer
137 views
Add Ajax to rating button
I have a ratings button in WordPress that outputs the number of people who rated the post. Is it possible to add the Ajax functionality so it doesn't refresh the whole page just the button number?
...
3
votes
1answer
290 views
Make a video post redirect to next post after completion
I want to make video posts redirect to the next video post in it's category after it's over. I use both youtube videos and directly uploaded videos both of which I already know how to pull the ...
0
votes
1answer
128 views
how to set beforsend option in wordpress ajax methods
How do I set the beforesend option in WordPress AJAX? I want to show loading option.
This is my code:
function showmyvideos() {
var datas="data";
var data = {
action: 'my_vids',
...
0
votes
1answer
347 views
How to use ajax to get multiple outputs?
jQuery.ajax({
type: "POST",
url:"wp-admin/admin-ajax.php",
data:'action=nafham_list_cats_selection&selection_id=' + $selection_id,
...
1
vote
1answer
136 views
Ajax requests with different WordPress Address and Site Address setup
I have a user using my plugin with the following wp setup
WordPress Address (URL)
http://server1.theirhost.com/~acct/somewebsite.com/wordpress
Site Address (URL)
http://www.somewebsite.com
I am ...
0
votes
2answers
101 views
AJAX call - failling to call do_action
I am trying to make an AJAX call for a plugin.
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script ...
0
votes
1answer
527 views
Ajax (jquery) wp_query pagination returns -1
I am currently developing an ajaxified theme for wordpress. I am listing the posts in a particular category, but the pagination returns -1 when clicked. Lets say I set showposts to 3 and a particular ...
3
votes
3answers
3k views
Admin ajax request return 0 with die()
So i'm using this configuration for an AJAX call in the administrative area (like this):
add_action( 'admin_head', 'ajaxPerNgg' );
function ajaxPerNgg(){ ?>
<script type="text/javascript" >
...
0
votes
1answer
410 views
Fatal error: Call to a member function query() on a non-object in my ajaxpage
i am creating a new plugin,i got this error
Fatal error: Call to a member function query() on a non-object in my ajax page. how to solve this error.
this is my code:
if ...
0
votes
1answer
196 views
Allow access to stand-alone php file Wordpress
I am developing a wordpress theme and I want to use jQuery.load() to load data from a PHP file in my theme directory called process.php to a div in a wordpress page template.
I haven't had any issues ...
0
votes
3answers
225 views
Page reload occurs before request finishes
I wrote a plugin to send an invitation to a friend and am submitting a form using AJAX and used the tips talked about in 5 tips for using AJAX in wordpress and another article referenced in the AJAX ...
0
votes
2answers
382 views
Ajax call in wordpress not working for subscriber user
All
In my application there is notification system, when user click on that icon I want to make ajax call.
The problem id it works fine for admin user (Debug : 200 ok), but not for subscriber user ...
2
votes
1answer
333 views
How to create a specific frontend URL (not a Page) from a theme or plugin?
My theme implements an AJAX action that returns some dynamic content and needs some functions from the Wordpress environment. How can I construct a URL for the AJAX call in the most elegant and robust ...
0
votes
1answer
38 views
How to make pages that arent indexed for ajax applications
I'm using a content section on my homepage to switch through multiple loops with ajax tabs and to do that a tutorial told me to make multiple pages and assign each page with a different template which ...
1
vote
1answer
165 views
Using AJAX in wordpress theme
all
In my theme there is a notification at top.
After user login he can see the notification update.
when click on notification i want to make change in database alert field value 0 to 1.
My ajax ...
7
votes
2answers
486 views
How to make comments work for a post loaded per Ajax?
I am currently loading a single post using ajax. While the post loading works ok, I cannot get the comments to load. Here is my code:
My javascript to load the post:
<script>
...
2
votes
1answer
1k views
Why is a 500 error generated by admin-ajax.php not going into the Apache error log?
I'm getting 500 errors with AJAX on the admin side. However, these errors aren't being logged in the Apache logs so they're rather hard to debug.
Is there some way I can find out what they are?
...
1
vote
2answers
212 views
Wordpress theme ajax have_posts()
My goal here is to load the blogroll into my theme via ajax. But all that I can get as response is 0 (if I omit the die() line, else I get a blank response).
Here is my code:
js ajax:
$.ajax({
...
2
votes
2answers
675 views
Unable to get_the_content(); of a post in Wordpress via AJAX
I'm trying to ajaxify my Wordpress theme and I use the method described here and I'm now trying get_the_content of post via functions.php. Using jQuery, when I do alert(data) I get the 'title' echo ...
4
votes
1answer
1k views
wp_get_attachment_image returns different image size
It is a bug?
wp_get_attachment_image( $attachment_id, 'post-thumb-size-small');
Same code, called in template, and in AJAX call returns same image SRC, but different image width and height.
dumb ...
0
votes
1answer
56 views
Tabbed feeds with ajax vs. without on homepage [closed]
I have a tabbed section on my homepage where I call different feeds for new posts by category of my site much like the new youtube layout. I have 10 different feeds so my question is how important is ...
1
vote
1answer
185 views
How to post form in ajax mode and handle it in wordpress
currently I can only do it in a normal non-wordpress way.
So, does wordpress provide a solution for this circumstance?
0
votes
3answers
123 views
Trouble After Update, Removing Plugin
I'm editing this site http://www.millermusicproductions.com/ currently and I updated WP 3.0.1 to 3.3.1. After updating, the page now is zoomed in compared to how it had been and I have no idea why. ...