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 ...

learn more… | top users | synonyms

0
votes
0answers
10 views

Passing form data via AJAX to REST API And displaying results

I'm new to WordPress but have been programming PHP for a long time... I searched a bunch of questions but couldn't find what I need. I have a page with a search form that contains a few parameters ...
0
votes
2answers
1k views

How to add a “ waiting” icon for an ajax in WP frontend?

This is my search js code for processing search : jQuery(document).ready(function($){ $('#searchsubmit').click(function(e){ e.preventDefault(); var searchval = $('#s').val(); ...
2
votes
1answer
195 views

How to save dismissable notice state in WP 4.2?

In WordPress 4.2 the is-dismissible class was introduced to allow notices to be dismissed. This code is working to add the notice. function prefix_deprecated_hook_admin_notice() { if ( ...
0
votes
1answer
2k views

Using AJAX to run SQL statement and populate dropdown

I am trying to create a search where the user selects two different bits of data from the database and it then prints some results that meet requirements. I know I need to use AJAX, or something ...
1
vote
1answer
2k views

Proper way to load a single post via Ajax?

I'm loading single posts via Ajax into a div that I have set up on my index page. Everything is working fine in this regard. I want to use history.js to push/pop the state so if users enter ...
1
vote
1answer
550 views

Shortcode in AJAX popup

I am trying to use a shortcode from Ultimate Facebook plugin to display a FB connect button in an AJAX popup and can't seem to get it work properly. I searched and used the solution given by djb in ...
0
votes
1answer
12 views

Loading post template that contains a nested loop with ajax

I'm currently working on a project where I'm loading a post with ajax. I'm using get_post() to get the post, setup_postdata() to setup the post data, and get_template_part() to load the template ...
3
votes
1answer
56 views

WordPress AJAX Login Screen

In recent versions of WordPress, when you have been logged in to the dashboard a while with the page still open, WordPress times out your session and opens a login box. This box appears in a little ...
4
votes
3answers
4k views

Infinite scroll / lazy loading with NextGen Gallery

I'm working on a project for a friend that involves a massive page with 3,000+ photos. See: http://www.thepurplepixie.com/projects/purple-pixies-people-project/ Currently, I have pagination set to 50 ...
-3
votes
0answers
44 views

Post rating without plugins?

Is there any simple post rating snippet which will work when page is cached. There is many functions, for example this: <form method='POST' action=""> <input type=hidden name=rate ...
0
votes
1answer
15 views

Can't load search results with ajax

I'm trying to load search results on my page without reloading. I tried multiple approaches already, but I still can't make it work, despite using someone else's confirmed solution. Please find the ...
0
votes
0answers
20 views

Category filter with load more ajax

What I am trying to do is to do an Ajax request to filter posts on category click depending on the category id, then apply load more posts by ajax. Problem: when I fire the ajax call by clicking on ...
0
votes
1answer
23 views

Allow user to Upload image and manipulate it on the frontend

The site I am working on allows users to post things up for sale. In the form for creating their post, there is a simple file upload field. The problem is that sometimes when users upload images they ...
0
votes
1answer
568 views

Form isn't inserting data into database with ajax plugin

I've been working at this for weeks without success. I've figured out problem after problem with the code, but none of the corrections seem to fix my core problem. The form doesn't insert anything ...
0
votes
1answer
3k views

Ajax page load without reload

I am working on a script to load my page without refreshing. It is working as I want it except for one thing. The test site I have up is http://dev.dog-company.com . Only home About us and FAQ will ...
-2
votes
1answer
20 views

How to get posts from external website with tags common using ajax Json? [on hold]

Plzzz How to get posts from external website with tags common with current post using ajax Json and show it in my website.
0
votes
0answers
25 views

Is there a hack for using is_page() within the function.php file?

I've created a function in my functions.php that's called when the submit_form event is fired on the front-end. Here is the code: add_action( "wp_ajax_nopriv_submit_form", "submit_my_form" ); ...
0
votes
0answers
7 views

How to create a wordpress search with ajax with Relevanssi - A Better Search plugin

I am using Plugin Relevanssi - A Better Search for search with only words and phrases not only letters matching.And now need to change the search and create it with ajax but didnt know where to start, ...
3
votes
2answers
381 views

How to modify wp_ajax function?

I want to modify wp_ajax_find_posts function. It receives search string from find-posts form and delivers search results by ajax. Part of the function looks like this: function wp_ajax_find_posts() { ...
0
votes
0answers
13 views

Woocommerce ajax checkout submit

So, in woocommerce, when a product is purchased, the user is redirected to "review-order" page. I am tying to make it so that the "review-order" page is instead shown by ajax on the product page ...
0
votes
0answers
29 views

ajax returns -1 in multisite sub domain

i am using the same theme for 2 language site - i didnt use a plugin but rather created a multisite (i like it better) - but... i have a problem with ajax which seems to work for main site but not ...
1
vote
1answer
3k views

ajax for filtering posts by category in wordpress loops

I've been looking around for a way to filter my posts on http://www.waziproject.com/wazimagazine/ without reloading the page. So my question is if anyone can help me out to turn the following into a ...
0
votes
2answers
784 views

admin ajax php success returns 0

I have looked over many posts on here and other websites and nothing I do seems to work. What I am doing is, I have a custom template file and inside that file I have a div that I want to populate ...
0
votes
2answers
383 views

Show selected images on top in Media Manager

I've searched numerous StackOverflow and Wordpress Awnsers questions, but I couldn't find any solution that matches my situation or even remotely points me in the right direction. I have a custom ...
0
votes
0answers
25 views

Weird admin-ajax.php problem

In my site, each request on the home page is also making a POST to wp-admin/admin-ajax.php. 10.30.4.122 - - [21/Aug/2015:06:07:53 -0400] "POST /wp-admin/admin-ajax.php HTTP/1.1" 200 275 ...
0
votes
0answers
19 views

toggle ajax loaded content on second click [closed]

I am loading content from a post into a div using: <script> $(document).ready(function(){ $.ajaxSetup({cache:false}); $(".post-link-<?php the_ID(); ?>").click(function(){ var post_link = ...
1
vote
0answers
43 views

template_redirect or admin-ajax.php?

My plugin needs to be reachable by the public and accept query vars. When called, it will run some backend db tasks, call a 3rd party API and sometimes redirect. Previously, I was using ...
-1
votes
0answers
13 views

Ajax wocommerce order-received page [closed]

Is there a way to show "order-received" of wocommerce on a same page as checkout? (Preferably by ajax) Thanks!
1
vote
1answer
489 views

Retrieving JSON data in ajax request from media uploader

I'm having some problems getting my JSON data that's being passed via an ajax request. I'm trying to implement the media uploader into a plugins settings page. I've got it functioning properly using ...
0
votes
1answer
29 views

First time doing Ajax with WP, how to do it?

I have been trying to work this out from various posts over the years but just can't seem to get it to work as I am not a Jquery guru and I am struggling to get my head around it. My html: ...
2
votes
2answers
599 views

update_user_meta doesn't work with AJAX

I try to keep user subscription in a metadata var. The function is called by AJAX. Ahe AJAX is called but the metadata does not seem updated on frontend. Here is the code: jQuery <script ...
0
votes
1answer
2k views

wp_handle_upload returns empty error array

I am trying to do an upload via ajax and really dont want to use the regular wordpress media uploader. It is too much stuff and all i want to do is upload single image. I have everything working the ...
0
votes
2answers
638 views

How to use ajax in wordpress plugin to get data from coustom DB?

i have created php script that work great as stand alone. now i need to create this script as wordpress plugin. so i have created custom table in wordpress DB. then i tried to make the ajax call. in ...
0
votes
0answers
32 views

[jQuery]Autocomplete and $.post

I managed to solve it using Sisir's push in the right direction. Here's the javascript function: function render_edu_hook_javascript() { ?> <script type="text/javascript"> var ...
0
votes
2answers
31 views

wordpress ajax contact form - error 500

I've tried to create a simple ajax contact form plugin. all things seems good till user push the "send" btn. it sends error 500. this is my script.js codes: jQuery(document).ready(function(){ //Get ...
0
votes
0answers
9 views

Loading ajax does not run through filter the_content

I have created a quiz page with a list of question. I use ajax to load the question content into the quiz. However, only the first question which loaded directly (not through ajax) render correctly. ...
0
votes
1answer
30 views

Can't pass the variable from a select to PHP query

I'm trying to make a dependent drop down with AJAX. I managed to get the chosen variable but I can't pass it to the PHP. Here's my code: action.js window.onload = function($) { ...
0
votes
0answers
24 views

To get the data from the Database is not working?

The below code is reponsible to display a dropdown options that while selected a options a google map was appeared. But when I put the shortcode into my page the options are being shown. But the ...
0
votes
0answers
25 views

Wordpress ajax load more returns duplicated posts

I'm trying to load more posts from my custom post type via ajax call, it sounds like i'm doing everything alright but one thing which is causing the duplication issue. My load more button does work ...
0
votes
0answers
38 views

WordPress AJAX File Upload - FrontEnd

So I have been reading through every WordPress front-end AJAX file upload tutorial I can fine. Nothing is working for me at the moment. The one that makes the most sense to me is this one: ...
0
votes
1answer
42 views

I have to post data by AJAX in wordpress to another Website

I have to post data by AJAX in wordpress to another Website (http://123abc.com/register) .But I always get Error .This is my jquery AJAX code: <script> $(document).ready(function() { // ...
0
votes
0answers
23 views

After wordpress widget save (ajax call) tinymce editor gone, data not saved

I have made tinymce editor for textarea fields in widgets. I'm enquing scripts: wp_enqueue_script('tinymce', home_url() . '/wp-includes/js/tinymce/tinymce.min.js'); wp_enqueue_script('tiny', ...
0
votes
1answer
644 views

Load more posts with multiple queries

I've been developing a theme which uses the load more ajax plugin, everything is setup and working great with the main query. But, once I setup a new query for popular posts, the load more posts ...
0
votes
1answer
119 views

AJAX login without a plugin does not work. when add a action to function.php

I am using wordpress ajax login without a plugin. I want to not be allowed users access to the WordPress profile after login, Because i have designed a specific profile in the link: ...
0
votes
0answers
15 views

Infinite scroll in ajax

So, I have ajax enabled on my wordpress site as following: id within any anchor within the chosen div will be saved and used to find an appropriate php file then loaded at an appropriate content div. ...
0
votes
0answers
20 views

Declare inline background image in functions.php

I'm not sure if this can be done as I cannot find anything to help me anywhere no matter how hard i try. I'm using Ajax to load to in posts on the press of the button. the posts that are loaded in are ...
0
votes
0answers
33 views

Modify category archive page loop on functions.php

I was able to modify the query on the category archive page using global $wp_query; $args = array_merge( $wp_query->query_vars, array( 'tax_query' => array( array( ...
0
votes
0answers
8 views

Create multiple Instances of Ajax function and Control Variables from Template file

I received some help previously in order to build a Wordpress Ajax Load more function, However the site I am building is using different variances of this on different pages pages. The issue I'm ...
0
votes
0answers
11 views

Sendy ajax subscribe call with json [migrated]

I am trying to get user to subscribe on the website using sendy subscription form (via ajax). The problem is it shows no error and console.log stuck with "signing in...". jQuery( document ...
0
votes
1answer
741 views

Three level taxonomy dropdown frontend

I have a code in my functions.php to display 3-level taxonomy dropdown: $brand_taxonomy = 'county'; $taxonomy_name = 'Vietovės pasirinkimas'; ...