0
votes
1answer
17 views

AJAX values converted to PHP Variables?

I just started playing with Wordpress and I have a question about the AJAX side of things. I think that I understand how the AJAX front-end to server side processing, back to font-end works. But, I ...
0
votes
0answers
26 views

Social Media button function using jquery

I've wrote a fairly small function that I'm trying to get working. At the moment the jquery doesn't seem to have any effect on the html selected. I've checked the "inspect element" all file's are been ...
0
votes
0answers
47 views

admin-ajax.php not working after wordpress 4 update

n WordPress 3.9.2 access to admin-ajax was working for non loggedin users. When I upgraded the script stop working. I have the following code in functions.php function theme_name_scripts() { ...
1
vote
4answers
94 views

jquery won't load in footer

I wanted to move jquery to the site's footer, but that doesn't work. I've tried it with the following code. As you can see, I have a couple of another scripts and they load correctly on the footer. ...
0
votes
0answers
27 views

Iris color picker

i try to implement Iris color picker in my wordpress theme and it works fine, but when i include the Iris color picker's files i can't call a custom function via a tag. this is the Iris color picker ...
0
votes
1answer
35 views

How to load plugin before the wordpress jquery?

I'm fixing a wordpress plugin that uses a 1.0.0 version of jquery. The jquery version automatically included in wordpress is 1.11.0. In a test site, the plugin is dependent on the 1.0.0 jquery and ...
1
vote
1answer
79 views

What's the point of using Wordpress's built in admin-ajax.php?

I'm trying to understand why using admin-ajax.php is advantageous over doing something like this: add_action ('wp_loaded', 'my_ajax'); function my_ajax() { // Do Ajax, Check $_POST die(); } ...
0
votes
2answers
127 views

jQuery HoverIntent is not a function

I am working on a site that uses jQuery for a number of functions but I am having a repeating error: hoverIntent is not a function I have referenced similar questions on this forum and they ...
0
votes
1answer
185 views

How to use different jquery function of idangero swiper dependant on page template?

I have struggled with adding the idangero swiper jquery plugin to my site, but have managed to produce the code below. This works very well but only on the one custom page template defined in the ...
0
votes
1answer
327 views

Replacing select2 in admin backend for all selects

I originally posted this question as a javascript question here, but think maybe it would be better asked here. I tried adding select2 to all wordpress admin screens. However, since many selects are ...
0
votes
2answers
719 views

Function won't run onclick using Ajax

Ok, so my code is meant to be pulled from the function using the jquery code below, but it isn't pulling the code and I can't see why not. My pages code <script> var click_to_choose_user = ...
0
votes
1answer
272 views

Right way to update widget on dynamic new input field

I have code to add an input field dynamicly in my theme. I have testd it, as a metabox and it works. But, not in a widget. First add and update, that codes work, but when I refresh page or try to ...
0
votes
2answers
123 views

jQuery does not work

I am working on a project where I need jQuery for. I added this to my functions, and the scripts are loaded in my header if I watch my page source, but jQuery doesn't work. What am I doing wrong? ...
0
votes
1answer
152 views

How to load jQuery in the footer - nothing works for me

I tried all the solutions I found on the internet, including the ones I found here, but nothing works on my theme - jQuery always load in header. I try to use the one from Google, but I would be happy ...
0
votes
2answers
3k views

How to redirect non-logged in users to a specific page?

How to redirect non-logged users requesting for a specific page/URL to another page/URL and display a message like "for members only". I know its quite easy to code using !is_user_logged_in() ...
0
votes
1answer
1k views

Why a SlideShow (made using JQuery FlexSlider) can't work if I load it form functions.php but work if I load it from my footer.php file? [closed]

I have the following situation: I am carrying this pure HTML theme (that use BootStrap CSS framework) into a WordPress theme. This is the original pure HTML demo theme (I have the entire source code ...
0
votes
1answer
106 views

Execute Jquery when a specific page in my plugin is loading

I am building a plugin and I would like to be able to hide the wordpress admin side menu and top bar when a specific page is shown(or menu item clicked)? Should I call the jquery directly as a ...
-1
votes
1answer
42 views

AJAX: Wordpress filters inside $html do not work as intended

I am sending HTML content through some AJAX magic and while everything is working as I wish, the output gives something along those lines in the page: "http://permalink.comtitle" It's as if all the ...
1
vote
1answer
254 views

Is it possible to get a theme customizer setting from wp.customize using jquery?

I am wondering if it is possible to directly interop with the wp.customize api to get a value of a theme customizer setting. The way I am doing it now is using ajax to get a response from a php ...
1
vote
1answer
36 views

Not sure if enqueuing js scripts properly

When I put this code right above the closing of my body tag it works, but when I try to enqueue it, it breaks. I'm thinking maybe jQuery isn't getting called? The snippet is from here FUNCTIONS.PHP ...
1
vote
1answer
95 views

PHP mixed with some JS code to update Wordpress theme settings

I am working on my first Wordpress Theme but I am facing a little problem in my code. In fact, I have created a little page in the administration to change some settings on my theme and, for example, ...
0
votes
1answer
417 views

get content from page through AJAX

I'm using an wordpress theme and I want to load content through AJAX inside a page. I've added this inside my functions.php : function my_ajax_files() { wp_localize_script( 'function', ...
0
votes
3answers
966 views

How can I loop into two different DIVS without repeating the DIVs

I am having a little trouble trying to figure out how I can accomplish this: I have a container with two colums in it, a right and a left column. Each column will have 3 posts with a short excerpt ...
0
votes
1answer
206 views

Creating multiple category drop down

I'm trying to figure out on how to create a multiple category drop down to filter different types of post Here is an image of my work in progress ...
0
votes
0answers
143 views

jQuery conflict on EDIT POST page - Getting blank White Screen

I have made a button to show up on ADD/EDIT POST page with onClick function to import values and insert to custom fields. My button/script looks like: <script type="text/javascript"> ...
0
votes
1answer
96 views

Change CSS for logged in users

In my css i have a hidden div id: #example {display:none;} How can I set this to display:block for logged in users only? I am assuming using Jquery would be the best option here for best ...
1
vote
1answer
63 views

Ajaxing function in widget class

I want to ajax function declared in function Widget in widget Class ,it have arguments belong to the widget i try this code add_action('wp_ajax_my_func', 'my_func'); ...
0
votes
1answer
267 views

In jquery use php variable to execute an enqueued jquery file

I am loading some jquery on a specific Wordpress admin page, the jquery loads and works fine but I need have this jquery only trigger if a php variable exists. In php I would just write a function ...
2
votes
1answer
164 views

How to load some jquery code to make validation in the theme customizer?

i am tring to load some jquery code to make validation in the theme customizer. i have created 10 checkboxes to show some info. but i want to limited the user to choose only 5 checkboxes. so i have ...
0
votes
1answer
191 views

enqueue script if page is not equal to

I'm registering some js scripts in my function.php, I have 2 versions of one js file, one FOR the homepage, and one for every other page. I've managed to get this to work to register the homepage ...
0
votes
3answers
755 views

JQuery undefined and Stylesheet loads in bottom along with js files

I'm developing a theme for wordpress and I'm using this function to enqueue scripts and styles function Joy_scripts() { wp_enqueue_style( 'Joy-style'); wp_enqueue_script( 'Joy-scripts', ...
0
votes
0answers
52 views

Highlight posts currently being edited on multiple editor site?

I have a custom page that uses the Cleverness To-Do List plugin to display multiple posts on a page. My site has multiple editors, and if a post is currently being edited on the custom page (not the ...
0
votes
1answer
89 views

How to disable controls in theme customizer?

Edit: I have rewritten the question in hopes I will get a reply from someone who knows the theme customizer. I am trying to figure out how to disable setting controls in the Wordpress theme ...
0
votes
2answers
316 views

Theme not calling Jquery properly

I am developing a theme and I have called jquery along with other JS files from a theme-enqueue.php file. For some reason only the Jquery file that is hosted on googles servers is adding the theme URL ...
0
votes
1answer
290 views

How to setup a popup registeration page in wordpress with function.php

everyone: I wonder if there is existing tutorial on how to create a popup registration page in wordpress by utilizing function.php? or is there another way that can do with it? Thank you!
1
vote
0answers
464 views

jQuery Plugin to use Wordpress functions in AJAX request

I'm using Chained Selects jQuery Plugin to create multiple chained selection fields. I'm using the remote version of the plugin to build the related options by means of AJAX request from a separate ...
0
votes
1answer
186 views

colorbox not loading in <head>

I can not get colorbox fully loaded. I am trying to add color box to use in my plugin admin. I do not need it for the front end. I can get the css but can not get jquery.colorbox-min.js or the ...
0
votes
1answer
197 views

Add a jQuery Function

Forgive me for knowing next to nothing about coding. BUT, I am calling jQuery in functions.php, which I have been told is the best way to include jQuery: //Get jQuery function modify_jquery() { ...
0
votes
1answer
216 views

JQuery prepend a function

I am trying to see where I went wrong with this code. I was trying to prepend the avatar and user meta above the admin menu. I get header already sent messages as well since the code is just right ...
0
votes
1answer
373 views

Call javascript functions from each page

Is there a plugin that supports calling custom functions that you've created? Like, page A -- I want to call function x $(document).ready(function(){ call_function_x() }); page B -- I want ...
0
votes
1answer
2k views

Can't call Javascript function - scope?

I get a method not defined error when trying to call a function loaded with wp_enqueue_script from site.js. I'm guessing it's because of scope caused by the jQuery ready wrappers? How do I get ...
0
votes
2answers
1k 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 ...
0
votes
1answer
161 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
1answer
326 views

Custom theme, contact form 7 & fast secure form doesn't work

I have problems with the plugins CF 7 & FSF. When I paste the code [si-contact-form form='1'] for FSF I get the result of the code "[si-c..." itself when I load the page instead of a form. I ...
1
vote
1answer
354 views

Load jquery only for certain pages in the backend

I have a set of custom theme settings in my functions.php file. In order to arrange some things I want to load jquery ONLY to my functions.php file. What I read in wordpress is this: If it was ...
0
votes
2answers
613 views

Remove swfobject.js in wp_head()

I have gotten rid of the wlwmanifest_link and jquery, since I load it from a compressed version and at the footer, but I can't find a way to get rid of the swfobject.js. This is the code I used to ...
0
votes
1answer
74 views

Help with IF has focus then… statment

in a sidebar I have: <div id="my_id"> [shortcode]</div> It outputs a title that when hovered on drops down to show a menu. When hovering on the title a background color shows up and ...
0
votes
1answer
600 views

How do I get my nav menu to show sub pages?

http://webdesignsalemoregon.com/westernmennoniteschool/ is my website. I've got the top menu which is the one that was in the theme when I started to customize it. It's got a test drop down that ...
1
vote
3answers
5k views

Unhook jQuery from WooCommerce via `functions.php`? [closed]

So I am using the http://woothemes.com/woocommerce/ plugin for eCommerce and it's registering jQuery local and conflicting with my default jQuery call from Google CDN. It took a long time but I ...
2
votes
2answers
1k 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 ...