jQuery is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development. jQuery is included with WordPress, and available to both themes and plugin developers.

learn more… | top users | synonyms

0
votes
2answers
24k views

How do I Upload/Import Form (Input) Files via. Ajax function?

I keep running into an issue getting the file(s) added/switched to ajax so that the server ajax handler can deal with the rest. How can I get the $_FILES to be passed the same as with the default ...
1
vote
0answers
716 views

How to bind data-src attribute for the image in the post using jquery?

I'm trying to use foresight.js for responsive image in the wordpress blog. For that I have to add the data-src attribute in the place of src in the <img> tag. Or I have to get the url from the ...
0
votes
1answer
114 views

JQuery Issues With Wordpress Theme Interface

I'm having a back-end script issue with a recently installed theme. I took it up with the theme developer, but they are of no help (that's another story for another time). I apologize if this is ...
0
votes
2answers
503 views

Dynamic WordPress editor in meta box

I created the WordPress editor using wp_editor function dynamically. While i click add more button i just cloned editor and append new editor using jquery. While i am cloning editor i just changing id ...
0
votes
1answer
1k views

jQuery drop down not appearing for autocomplete/autosuggest

I have set a field to autocomplete/autosuggest but the drop down isn't appearing as I type. I can see the admin-ajax.php requests and the data returned in the Network tab of Chrome Developer Tools so ...
0
votes
1answer
1k views

Trying to get fittext to work in Wordpress

I have the following code in my template page and I have registered jquery and fittext in my theme's functions.php. They are currently showing up in the footer as I set them to. I can set them up in ...
1
vote
1answer
71 views

Ajaxify calendar

I need ajaxify "next" and "prev" links in wordpress calendar for navigation of months, without updating the page. There is some plugins for this - but I call calendar without using widgets - ...
1
vote
0answers
260 views

Validating a cloned/repeatable input (jQuery)

I'm trying to create a repeatable field an upload image input with image preview for my Theme Options page and I have the following: function theme_options_validate( $_POST ){ if ...
0
votes
1answer
488 views

How to use wp_update_post with ajax on frontend

I've been working hard trying to implement a frontend post editor "sidebar" on each post when I'm logged in. You can see what is going on here with a test post: ...
0
votes
1answer
338 views

How To Include JavaScript Files Only In Single Posts?

I know that wp_enqueue_script() inserts Javascript files into the WordPress header in the appropriate place. However, I want to include my Javascript in all single posts, ignoring the WordPress home ...
3
votes
4answers
7k views

Check if user is logged in using JQuery

I want to execute custom jquery code which shows login dialog to user if he clicks a button and he is not logged in. How could I do that?
1
vote
0answers
775 views

Uploading PDF using Media Uploader

I have been using a custom code to upload images to Wordpress using custom metaboxes. Here is the code: <script type="text/javascript"> jQuery(document).ready(function( $ ) { var ...
1
vote
1answer
4k views

How can I check email exists via a jquery keyup()?

I have setup a jQuery keyup delay function to check the email typed into an input field. It works fine after testing with an alert('Key pressed!'); But I want it to say, for example, 'Yes this ...
2
votes
2answers
1k views

Twitter Bootstrap Use Collapse in Custom Post Type

I am using Bootstrap with Wordpress and I want to implement the collapse functionality in the content for single pages of a specific custom post type. I know I could create a shortcode, however, ...
0
votes
1answer
364 views

Category List and Automatic jQuery classes

Objective and layout: I have two separate divs (this is in a Custom Page template). DIV1 has a listing subcategories of a specified parent category. Clicking on any of the listed subcats brings up a ...
0
votes
2answers
155 views

“Conflict” with jQuery (or its plugins)?

I've been working on localhost and everything looks fine but then when I uploaded my Wordpress theme online, all of the jQuery plugin functions are undefined! One solution that worked (which I ...
4
votes
2answers
4k views

Most efficient way to add javascript file to specific post and/or pages?

I am wondering what the most efficient method is to add a javascript file specifically for a post and/or page. Here are a few solutions I came up with: Switch to HTML editing view and post your ...
0
votes
1answer
1k views

wp_enqueue_script won't load in header?

Read up on this, and I believe I'm doing everything right. Everything is getting loaded in the footer. Here is my code: function load_kenburns() { if ( !is_admin() ) { wp_register_script( 'kenburns', ...
0
votes
1answer
49 views

displaying the categories post

I have this php code below for displaying the post from the specific categories. <ul id="sliderx"> <?php query_posts('category_name=slideshow&showposts=10'); while (have_posts()) : ...
0
votes
2answers
2k views

How to add php within jquery

I want to add php code within jquery. I know that the file then cannot be saved as a js file but must be saved as a php file to execute the php code. If we save it as a php file then it can also not ...
-2
votes
3answers
83 views

Why is jQuery not working properly? [closed]

I've enqueue'd jQuery from Google and it's displaying in the source code but no matter where I put my scripts they don't seem to work. Here is the site in question - http://www.deanelliott.me/handh/ ...
0
votes
1answer
204 views

Pass WP post content to a jQuery plugin (Fancybox)

I'm building a portfolio WordPress. It only displays image thumbnails, with a video element that call the fancybox. In the <a> tags, the attributes have the information for the fancybox to load ...
0
votes
1answer
285 views

How to keep track of when a vote is cast?

I have setup a great voting system on my website, but since I want to sort the top rated posts by week, month and alltime...I now need to able able to keep track of when a vote has been cast. Could ...
1
vote
2answers
1k views

how to add Jquery script to one page?

What is the best practice to apply an individual script to a particular page? When I try to apply the script of the whole page it has problems with other plug-ins. Is there a rule of thumb? ...
-1
votes
2answers
112 views

jquery stopped working after deregistering wordpress stock version

I had two instances of jquery in my code and everything used to work. I decided to get rid of wordpress stock jquery by deregistering it through functions.php file. But now not a single jquery ...
2
votes
2answers
841 views

The correct way to call posts with ajax

I'm trying to write an image gallery plugin with jQuery. I'm using jQuerys $.post AJAX method to send and receive info from the relevant post page. Basically I'll be looping through the attachments ...
-1
votes
1answer
374 views

Using AJAX in a Widget to Sort items [closed]

Hi I am trying to use jQuery sortable to sort items in a widget on the admin side. However I am having trouble getting any data in the JS file when I do alert(order). Any idea what might be wrong ...
1
vote
0answers
279 views

Load the next posts ajax

I use the below code to display the first 5 results. <ul class="category_list_view" id="widget_index_upcomming_events_id"> <?php global $post,$wpdb; $post_number = 5; $category1 = $category; ...
1
vote
2answers
2k views

Can I include Javascript/jQuery in a page?

I'm extremely new to Wordpress, and I've offered to help out with a project that uses it. In a new page I'm creating, I need to use javascript/jQuery to write out the html dynamically - it doesn't ...
0
votes
1answer
157 views

jQuery dialog prints HTML-Tags under Wordpress

i need some help. I am using wp_localize_script in my Wordpres_Plugin. Inthe documentready-function i use this Code to bring the Message up: $('#button-setup-league').click(function() { $( "#dialog ...
-1
votes
1answer
169 views

Integrating jSquares and Jquery with Wordpress loop

I am trying to integrate jSquares with wordpress and I am having a couple of issues. I am a beginner developer - but would love to solve this problem so that anyone can use jSquares with Wordpress. ...
0
votes
1answer
175 views

Ajax call does not work for this custom code

I have this ajax call which gets the value for catname: jQuery('.bio a').click( function(){ var catname = $(this).closest(".bio").data('category'); alert(catname); jQuery.ajax({ ...
0
votes
2answers
130 views

wordpress before or after javascript problem

hi guys im aqeel im trying to implement a slide show in a wordpress site's home page but it not working it simply contains the easyslider1.5.js file which i put in js folder css which of course in css ...
1
vote
1answer
918 views

Error when posting comment form: The error is TypeError: e[h] is not a function

I am getting an error when the function below posts the form (from the second time, the first time it is blocked). When I click the submit button after this, the form submits without problem. The ...
1
vote
2answers
691 views

Load comments per post on click with AJAX

I'm working on a theme that uses a slider to display blog posts. Beneath the slider is a pagination that displays like a timeline, with a date instead of a page number, calling the corresponding blog ...
-1
votes
1answer
564 views

How to combine jQuery in-place editor with $wpdb->update

i am trying to use jQuery in-place editor (http://code.google.com/p/jquery-in-place-editor/) on WordPress to update certain values of a custom made table in my database. I am not really skilled with ...
1
vote
1answer
284 views

Ajax comments not working

I followed a tutorial to 'ajaxify' wordpress comments where it does not reload the page: jQuery('document').ready(function ($) { $('#commentform').each(function () { var commentform = ...
0
votes
1answer
99 views

How to enque js script in footer that are not in .js file?

I do have code that is js script inline together with php script is their possible way to enque it to footer without puting it on .js file To clear explanition on my question here is my example code ...
0
votes
1answer
491 views

How do I make my wordpress post appear in a mouse hover preview?

Mouse hover previews usually only show title and image. Instead, I want the entire wordpress post to show. The code that calls the preview is this: adTitle = jQuery(this).find('img').attr('alt'); ...
1
vote
2answers
2k views

wp_verify_nonce not working

I'm working on an ajax request, I have several ajax requests on my functions.php. And all are working, but this: On my php I have this: add_action("wp_ajax_fb_points", "get_fb_points"); ...
0
votes
1answer
790 views

Cannot enqueue jQuery correctly using Google CDN

The problem: I understand how to regularly enqueue jQuery UI in functions.php. My problem is that I'm using a selectmenu widget that doesn't come with WordPress by default: ...
0
votes
1answer
3k views

call shortcode in javascript

I want to display a shortcode through jquery after the DOM is loaded: This is how I call the shortcode: <?php echo do_shortcode('[plugin]'); ?> Now, my question is how can I call that ...
-2
votes
1answer
873 views

Use ajax response in PHP function

Ok, so I'm working on a plugin and just ran into a problem. Here's what I'm doing: 1. Using a metabox with Plupload to upload an image to an upload dir in the plugin folder. 2. Upon upload success a ...
3
votes
1answer
706 views

Help adding image upload functionality to widget

I am working on a small WordPress widget and I am trying to set it up where the user can upload an image. So far, the necessary scripts are loading but when I click the "Media Library Image" button ...
0
votes
1answer
321 views

enqueue jQuery into the footer

I have looked but no where seems to cover how to place jQuery into the footer, at least not the way I have it in my theme, is there a way to place the following into the footer? // Load jQuery ...
0
votes
1answer
34 views

Loops running into each other

I have 3 loops on one page, each pulling a different CPT into a portfolio like layout. Live: http://iassc.baltimoredrew.com/providers/ Gist: https://gist.github.com/3503334 However the tags for the ...
0
votes
1answer
35 views

Is it possible to append an external html file to my wordpress navigation?

I'm trying to add a hardcoded 'megamenu' style dropdown div to my wordpress site. The content of the div itself doesn't need to be administered via wordpress, it will all be hardcoded. I don't want ...
1
vote
1answer
925 views

Intergrating agile carousel to wordpress: how to write the ajax_callback function

json is totally new to me how to write an ajax_callback function for agile carousel to work in wordpress? Below is the jason data format that I need to write as php arrays for it could be parsed by ...
0
votes
1answer
203 views

Using jQuery .after inside loop

I have a bit of javascript that will dynamically add a static post to a loop. The script uses the jQuery 'after' method and on a static page it works beautifully but when inside the loop I don't get ...
1
vote
1answer
347 views

Script for initializing JQuery Masonry for Wordpress

What is the different between this (http://pastebin.com/PX0YB0hy) and (http://pastebin.com/VBqiMHVQ) for JQuery Masonry. Why does the first one work and the second one doesn't. In both cases I used ...