A client side scripting language useful for making interactive web sites

learn more… | top users | synonyms

0
votes
2answers
27 views

Dequeue script to prevent javascript event conflict on wordpress child theme

I've built a child theme of Divi Theme to use with Buddypress. So far so good, except for a script conflict on commenting buttons. The theme load a javascript (js/custom.js at 2642:2662) with the ...
0
votes
0answers
11 views

carousel in wordpress not work in theme (problem with 2 jquery js)

i use owl crasoul in wp theme but not load in home page and i use layer slider jquery layer slider: 1.8.3 jquery carousel: 1.9.1 when delete jquery of every not load other ! why? owl code: ...
0
votes
0answers
8 views

Locating and accessing the main js file

I'm hoping to find out exactly where this main.js file is located in wordpress and how to access it? "jQuery( document ).ready( function()"
0
votes
1answer
14 views

Handling AJAX with custom taxonomy custom fields on add

I wrote some extra fields for my custom taxonomy. I added the form fields to the add form. I got it to save by handling the appropriate values in $_POST. In 4.1.x, the add form is Ajax-ified. How can ...
0
votes
0answers
32 views

How do I get a custom field to work in google maps as a javascript variable [on hold]

I have a custom post type called "events" and I'm storing latitude and longitude in a custom field. I want the events to display in a google map. How do I convert a custom field in to a javascript ...
0
votes
0answers
32 views

Youtube No 'Access-Control-Allow-Origin' header is present on the requested resource error [on hold]

I have a strange issue on a site I am working on. I have added a link that opens a youtube video in a popup. It works fine on all pages, but if I do a search, something like ...
-1
votes
0answers
11 views

Gravity Forms: Show selected product + options at bottom of page

I've created an order form with Gravity Forms (Developer license). It's for a subscription box, and the user can choose a main product, a variation and either a monthly or 3-monthly subscription. ...
0
votes
0answers
21 views

Create modal/popup when clicking on “search” [on hold]

I've inserted a wp-search on a WordPress page. I want to display the search results in a popup window whenever any term or keyword is searched in the search box and the "search" button is pressed.
0
votes
0answers
20 views

Change php via js, is it possible?

i want to change my headers dynamically ( not in WP admin dashboard ) <div id="Header_wrapper"> <?php if( header_style == 'header-creative' ) get_template_part( 'includes/header', ...
-2
votes
0answers
17 views

With woocommerce variable products, how to I live update the price based on variations? [closed]

I have setup a woocommerce theme and setup products with various attributes. I have different prices for variations of product eg: size small, red tshirt is £12 Size large, red tshirt is £15. The ...
0
votes
0answers
16 views

Booking enquiry form with Javascript

I've to copy an old website to a new wordpress website. I've a problem with a form with Javascript... I would like to add the form like a widget under the sidebar menu. I succeed to reproduce the ...
1
vote
1answer
49 views

Switch to the library tab in the media uploader

I'm developing a plugin that adds a tab to the media uploader to add external videos to the media library via oembed. Everything works as expected but I need to switch to the library tab after adding ...
0
votes
0answers
11 views

Theme Customiser not live previewing changes on pseudo elements

I've been working with the Theme Customiser API lately and found that pseudo elements are not live updating using the previewer. In my project I have an image containing a transparent overlay using ...
0
votes
1answer
76 views

Move all the JS files to the bottom|footer, the right way

In order to speedup my site load and prevent scripts from render the page I'm trying to move all the possible scripts (meaning JS files) from head to footer. After read and do some research I made ...
0
votes
0answers
51 views

500 (Internal Server Error) of external php file

I am currently using WP Web Scraper version 3.2. Once I insert the shortcode or template tag (php code) directly into my page, the plugin works perfectly fine and the values appear. I decided to place ...
-1
votes
0answers
24 views

Uncaught ReferenceError: jQuery error Preventing Bootstrap Modal From Working

I have a script that automatically opens a modal popup 5 seconds after the page loads working on other non WP pages of my website. However, it's not working on my WP post here: ...
0
votes
0answers
15 views

None of the JavaScript works when using wp_editor

I'm trying to create a front-end editor for my Wordpress theme using wp_editor. While it outputs the editor, there's loads missing from it. There's no title, no submit button and none of the JS ...
1
vote
1answer
22 views

No data received

When I use the wp_register_script() and wp_enqueue_script() to load the jquery for the wordpress I got "no data received result with other information like this : Unable to load the webpage because ...
0
votes
0answers
20 views

Close TinyMCE plugin window on click away

I've created a small plugin which adds a button to the TinyMCE toolbar. When clicked, it opens a popup window via editor.windowManager.open(). That popup can be closed by (1) clicking the "Cancel" or ...
3
votes
2answers
85 views

Allowing admin-ajax.php to receive “application/json” instead of “x-www-form-urlencoded”

I'm using AngularJS's $http function to send my payload to WordPress's admin-ajax.php subsystem, but it seems the latter only accepts x-www-form-urlencoded data, instead of the application/json ...
0
votes
0answers
7 views

How to make post title a Google Maps marker? [migrated]

I want to have a Google Map displaying the post title as a marker. This code works in my posts (via header.php) and shows the basic map (code from Google): <script>function initialize() { ...
0
votes
1answer
40 views

Why is my script not working?

I know PHP, HTML, CSS and JavaScript but I'm kind of new when it comes to wordpress and digging in the source code. How ever I have made a very simple JavaScript Script. There is 1 .js file with alot ...
0
votes
1answer
33 views

I want to enqueue a .js file to my child theme

I tried to enqueue a custom .js file in my child theme directory. In the functions.php of my child theme I find the following code /* After this. you can override Accessible Zen's pluggable ...
0
votes
1answer
18 views

Custom JS text area in customizer is being formatted wrong in document

I have created a wordpress theme, in the wordpress theme customizer I have added a couple of text areas where a user can input their own CSS or JS to be added to the head. The placement of the text ...
0
votes
0answers
39 views

WordPress 4.1 Javascript Error

I'm working on a WordPress site and am getting a JavaScript error in the admin area when editing a post, which causes much of the JavaScript interactions to fail. I've activated the default theme and ...
0
votes
1answer
39 views

Theme now uses require.js and enqueue script no longer works

I created a small custom script that fixes a sidebar at different point depending on if there is a banner. I used enqueue script in my child functions file and then a custom.js file with my ...
0
votes
0answers
20 views

Issue with replacing apostrophe in URL string [migrated]

I've tried escape, replace, split and join and I can't seem to get rid of the ' in the category title: Over 60's var dropdown = document.getElementById("cat"); if ( ...
0
votes
0answers
13 views

Insert custom taxonomy into javascript

I have a simple javascript to display a future time. The script is executed from post's content. <script type="text/javascript"> <!-- var currentTime = new Date() ...
0
votes
0answers
23 views

Trying to uswp_localize_script with Advance Custom Fields Repeater

I have an external javascript file that I am trying to change dynamically: Here is the Javascript that I want to be dynamic slides : [ {image : ...
1
vote
1answer
31 views

Wordpress Plugin with a shortcode that dynamically generates javascript. Can I use add_action without wrapping the javascript in a function?

Looks like the best way is using: add_action('wp_footer', returnJs); But if my returnJs function is inside my shortcode function and it's used more than once on a page it will return an error trying ...
0
votes
1answer
16 views

Creating custom URL for async content

I am using a fully asynchronous Javascript/jQuery portfolio gallery (Grid Gallery template in Photolux theme). When a portfolio item is clicked, the item's details loads. It is built-in in the ...
0
votes
1answer
33 views

Displaying contents of a tab

I have been trying to figure out how to accomplish what I need done which I can show here . I had asked this question in StackOverFlow which I got a good answer but I don't know how to implement it i ...
1
vote
0answers
35 views

Refreshing collections in the admin media manager

I know this question is very similar to this previously asked question; however, I was wondering if there was a more up-to-date/official way to refresh content programmatically in the WordPress admin ...
0
votes
0answers
23 views

Wordpress search query

I used code snippet, from the plugin http://wpadvancedsearch.com/, which works very well, but when I press a search button, it generates the following string in the URL: /?search_query=& and I ...
0
votes
0answers
8 views

Admin Categories validation

i am trying to validate user input when adding new category through WP , i use jquery.validate() and validation error appeared successfully , but after pressing add new category , the category is ...
1
vote
0answers
37 views

Media Upload , file name changed automatically

I face a problem that when i upload a video that named in non-english language , for example : Arabic , it placed in uploads folder with strange name Ùيديووو so it can't be access through ...
0
votes
0answers
13 views

Disable drag metaboxes, create many functions using js not to work!

when i Disable dragging metaboxes in admin, it seems to make some problems. when i use this code: function disable_drag_metaboxs() { wp_deregister_script('postbox'); } add_action( 'admin_init', ...
2
votes
2answers
286 views

Loading different JS for http and https

I'm using a third party JS file. And they have both http and https version. My site have some pages loading in https while most of pages are in http. Now my question is could I do something in ...
0
votes
0answers
83 views

admin-ajax.php taking a really long time to respond?

I'm loading posts via Ajax and I noticed that it's taking on average about 4-5 seconds for the response. Is this normal? Is there anything I can change in my code below to speed things up? I'm not a ...
0
votes
1answer
29 views

How would I get this to work - send to post from thick box

I have the following javascript which talks to about 6 elements. The first three open a thickbox for media upload and what not upon clicking on a specified button, the last three target the input ...
0
votes
1answer
24 views

JS files landing on page but not working, using childtheme of twentyeleven

my functions.php from child theme, does not seem to allow the script to run in the page, it works on the styles using @import url. do I need to do something like that with the Javascript or is there ...
0
votes
1answer
25 views

TinyMCE Javascript URL Question

ed.windowManager.open({ file : url + '/shortcode_generator_popup.php', I would like to move this file one folder above the current one that it's in. I'm wondering how I can rewrite ...
0
votes
1answer
77 views

Make tinymce button have a checkbox that returns a value, instead of true/false

from my understanding the checkbox of the tinymce buttons only return true or false? Is there a way to get a checkbox list? And all the item's values inside the checkbox list that are checked will ...
0
votes
1answer
51 views

Why are some custom javascript files working but some are not

I added some custom javascript files to my wordpress page. I put them in the funcstions.php like this: wp_register_script('formfunctions', get_template_directory_uri() . '/js/formfunctions.js', ...
0
votes
1answer
140 views

Trying to get single posts to load on the front page via ajax

I posted a similar question about this before but I changed a bit of the code so I figured I'd start a new topic. Below is the setup I currently have to load single posts on the front page. This is ...
0
votes
0answers
134 views

Add title and caption to thumbnail image on mouseover

I'm trying to add a simple mouseover image to display the images title and caption data. I've added the js in my scripts file which is being called okay yet the rollover is not working. Essentially I ...
0
votes
0answers
38 views

I'm doing this single page website the right way?

I'm making a single page web site using WordPress and I want to know if I'm in the right direction, and if this is the best way do it. First I'll show how the website is structured, it has 4 pages: ...
0
votes
1answer
94 views

How to make Isotope and Wordpress work together?

I am trying to make my Wordpress theme using Isotope plugin. http://isotope.metafizzy.co/ So far, I have such a result after doing that was suggested: I believe that Isotope Masonry should not ...
0
votes
1answer
81 views

AJAX Success Function using JS substr() fails in WP 4.1 vs 4.0

For years I've set up php ajax calls and responses in my plugins like the following, with js error detection conditions as needed like... if( "<e>" == msg.substr(0, 3) ) { do_something(); } ...
0
votes
0answers
51 views

how to pass variable of shortcode of wp to javascript

I have create a shortcode of google map in my theme. whole code is below. function google_map_view_scripts() { wp_enqueue_script( 'googlemap', get_template_directory_uri() . ...