A client side scripting language useful for making interactive web sites

learn more… | top users | synonyms

1
vote
1answer
33 views

How do I remove the date and category form my portfolio pages

This is one of my portfolio page Whenever I wanted to remove dates and category from blog posts I always used this code function jl_remove_post_dates() { add_filter('the_date', ...
0
votes
0answers
50 views

WP Disclaimer Popup Plugin Tweak

I am using WP Disclaimer PopUp by Art Armstrong and it is really perfect for what I'm doing. However I need one small simple tweak. I tried to hire him to do it but didn't get an answer. Whoever ...
0
votes
0answers
32 views

Javascript in WordPress Navigation - mobile menu

I added a Live Chat link to my WordPress navigation menu. I followed the Ideal solution #2 below which works great on the desktop, but not on the mobile menu. It doesn't do anything on mobile. Any ...
8
votes
3answers
239 views

Any advantage of using wp_scripts and is_IE when enqueuing scripts

I read on the WP docs, which pointed to this gist that the correct way to enqueue styles for IE is by using the $wp_styles. I'm guessing that this would be true then for scripts as well. Take these ...
-1
votes
1answer
96 views

Gravity Forms closes my popup on Validation Error [closed]

I am having an issue with Gravity Forms. A user on my site can open a contact form in a popup menu by clicking a 'contact' button. The form is just in an absolute div that I show/hide on the contact ...
0
votes
1answer
93 views

Combining results from WP-API using AngularJS

I currently have this site - http://dev.5874.co.uk/scd-data/ where I have a dropdown which displays results from WP-API which I am pulling in through AngularJS. It currently combines the two sets of ...
0
votes
1answer
141 views

Custom Plugin - CSS works, JS doesn't

In the plugin I'm making, I use separate js and css files (____.js, ____.css). This is the first time that I've included an external .js file in anything. I'm registering and enqueueing both in the ...
0
votes
2answers
44 views

Inserting ads within content

I want to show adsense ads below the 4th and 20th paragraph of every blog post, ONLY if there is a 20th paragraph. I managed to insert an ad below the 4th ad by placing the following code in my ...
1
vote
0answers
56 views

PhantomJS with wordpress

I know it sounds basic but I'd really appreciate some help/guidence on how to use phantomjs on my wordpress project. I'm using Windows 8.1 and local host with xampp for now. I've downloaded phantomjs ...
4
votes
1answer
7k views

AJAX filter posts on click based on category

This is my first foray into AJAX, I've been splicing bits of code from various tutorials which probably hasn't helped. I have a list of categories on my homepage (index.php) and a list of the most ...
1
vote
0answers
12 views

Weird issue with slider on javascript

I have a page that i am using revolution slider on the page and everything works fine. I have a global javascript that runs on each page that looks at the url variables on the page, city and tel and ...
0
votes
1answer
59 views

how to do open a link in a open window from menu bar? [closed]

I am working on a word press site. When I click on a entry in menu bar, it should open that link in a new window. I know how to do this for a button but not sure for a list item. This is the code ...
24
votes
1answer
5k views

Is it possible to reuse wp.media.editor Modal for dialogs other than media

To expand: I'd like to utilize the same Modal code/appearance ( as used in wp.media.Modal, wp.media.FocusManager ) to open a modal of my own custom dialog, not the Media Editor. In the past, I've ...
1
vote
0answers
57 views

Audio Player not loading when the content is loaded through Ajax, MediaElement.js no applied

When I load the content using ajax it doesn't apply MediaElements.js to my audio player, so the audio isn't display. I think this is because the MediaElement.js is loaded with wp-footer(), and this ...
0
votes
0answers
12 views

Can't see audio when I acces with ajax

I have created an ajax portfolio. It works fine, but when I upload an audio, this is not display. If I acces to the post via my blog page the audio is there. I inspect this file and I discover a ...
1
vote
1answer
54 views

Push metadata in array

Applying meta keys in search result Since I need to take on a different approach to get my data in javascript from wordpress, I am trying to apply (as follow up on my post earlier today ...
1
vote
1answer
57 views

How can I output a php value into a JS file within Wordpress?

I am trying to use get_theme_mod option from php to load into my js file. I've used wp_localize_script to convert. The tweet_id is where I need to place the $tweet value outputted. Any help would ...
2
votes
5answers
4k views

Asynchronous Javascript Loaders

I'd like to take advantage of loading my scripts while the page is loading. ie. Yepnope, head.js etc... But I also want to be able to enqueue the script so other plugins don't try adding their own. ...
-1
votes
1answer
188 views

Passing javascript variable to php file

I can't find the best way to pass a JavaScript variable to use in a PHP file. I found this function wp_localize_script(), but it does exactly the contrary. Is there a way to pass a JavaScript ...
0
votes
2answers
65 views

load ajax using admin-ajax.php

The append result is 0, instead of a list with the title ass a link. If I check this locally (http://localhost/wordpress/wp-admin/admin-ajax.php?action=lateral_fluid), I get the titles ass a link. I ...
1
vote
0answers
36 views

Add custom JavaScript that is a combination of CDN/uploaded files and easily-edited code?

I would like to add some custom JavaScript to my site: a combination of external CDN-hosted files, static library files hosted locally, and local JavaScript that I'd like to be able to edit in the ...
1
vote
1answer
27 views

I am facing a problem with the navigation menu of my website

The link to my website is http://ashevilleandbeyond.com/ and when you load it on your browser, for a few initial loading seconds, you will notice that the menu items are visible at the top left side ...
0
votes
1answer
79 views

Facebook share button only share the_permalink(), without thumbnail, tilte, excerpt, etc

I'm trying to add socials to my post. I can share the post, but only the post URL. How could I share the post thumbnail, the Title, the excerpt, the author, etc. This is what i'm trying: HTML (in ...
0
votes
1answer
219 views

How do I make multiple dependent input fields that use the jquery autocomplete function?

I'm trying to create a form that will allow the user to add a new listing on the front side of my equipment classifieds website. I have a custom post type set up with a custom taxonomy called ...
1
vote
2answers
5k views

Repeatable custom meta fields

I am working on creating custom meta boxes for the back-end of WordPress. I would like to add a metabox with several fields, in my case an image upload and a text input, but with a button that can ...
1
vote
0answers
81 views

Call javascript function when category was added via ajax

I've created a plugin to handle featured images for categories (well, for custom taxonomy actually, but it doesn't matter). Everything is working fine, except the featured image is not cleared after ...
0
votes
0answers
19 views

Run script when media uploader is opened in post

I've added additional fields to attachment fields so that the user can select a photographer either from a dropdown that has a list of photographers, or you can put your own photographer. For that ...
0
votes
1answer
1k views

Adding an onchange event to a custom dropdown menu in Wordpress

I would like to add an onchange event to a dropdown menu I've created via my Wordpress plugin. As this is my first foray into Wordpress development, and the company I work for has a tall order for ...
0
votes
3answers
26 views

jQuery search function not running in Wordpress but running locally (fiddle)

as the title suggests, I am running into this annoying issue: The search is not working in wordpress but it is working in the fiddle and locally. The sorting is working in wordpress. I have the ...
0
votes
1answer
50 views

How should I go about registering JavaScript that isn't a file? [duplicate]

For a plugin I'm creating it generates custom JavaScript that should be executed in the footer of the page. Being that it's custom JavaScript, I can't simply put it in a file and register & ...
-1
votes
2answers
35 views

Unable to change the location of a file

I am unable to change the location of src attribute mentioned below <img class="srcimage" src=server-side4.php/> I want to change it to src=scripts/server-side4.php This is the javascript ...
1
vote
1answer
47 views

WP functions in .js

I have a huge main.js which includes 99% of my JS + plugins' JS. While loading time is a little bit longer when user visits the site for the first time, it gets cached and there will not be any other ...
0
votes
1answer
55 views

Detect Featured Image remove while editing post in wp-admin (client-side)

I'm looking to add some client-side (JavaScript) events to the post edit screen of wp-admin (post.php?action=edit). I wish to fire events when the user selects a new featured image and a different ...
1
vote
0answers
182 views

How to refresh Theme Customizer after change color inside wpColorPicker?

I develop my custom widget with setting where I can set up custom color for the widget. I use this code to initialize wpColorPicker instead of default text input in form() method of Widget class: ...
1
vote
1answer
254 views

Wordpress Rest API

I'm trying to call a post from a Wordpress install using WP REST API. I keep getting an error in return and I can't find out why. Do I need to authenticate? One website said I don't need to ...
0
votes
4answers
649 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 ...
1
vote
0answers
33 views

Redux Framework: Page freezes on typing in Editor

I am using Redux Framework. I am facing an Issue with the editor in Theme Options of Redux Framework Currently I have 103 editors in the options. My Issue is that whenever I start typing ...
0
votes
1answer
39 views

Why is this script not working?

I've got the script from here http://www.mikedoesweb.com/2012/convert-tag-to-google-maps-embed-automatically-with-jquery/ I need to replace an address with a google map inside the post content. None ...
1
vote
0answers
19 views

wordpress 4.4 upgrade visual editor bullets select for not selected elements

Please check attachment for reference image and help me to fix it please.
0
votes
0answers
28 views

How to how to open the add media dialogue it in a certain state / tab

I created a customized wp_view similar to embed (see wp-includes/js/mce-view.js, l. 868). I also have my own tab in the "add media" dialog. Naturally i want the edit button of my wp_view opening the ...
0
votes
0answers
26 views

How to reference tinymce body in my script

I want to add some custom behaviour to my tinymce body, but I can't reference it in my script. this is how I load my scripts inside my wp plugin. $this->loader->add_filter( ...
2
votes
1answer
28 views

Run a Parallel PHP Application with Wordpress

I have a PHP based application that runs on the Google Maps API. Most of it is written in straight PHP and Javascript, but I want to use some sort of CMS or tool to upload images, because there will ...
1
vote
1answer
28 views

Creating multiple enclosing shortcodes and fixing JS issues on click

I have the following shortcode to create multiple 'more' sections in any page/post: function more_shortcode( $atts , $content = null ){ return '<div id="more-outer"><a href="#" ...
0
votes
1answer
17 views

Meta Box - Javascript Datatable

Hello my fellow WP Developers, I am running into a wall with a custom theme I am creating for a personal project. Background It's a website that will be used by users that collect a specific ...
1
vote
2answers
154 views

How do I embed a Javascript form directly into a page?

I have a new WP install with the Jupiter Theme installed. I have a contact form created in Sharpspring, a CRM that purports to work perfectly with WP, and automatically generates embed codes for ...
0
votes
1answer
79 views

JavaScript and Google PageSpeed + wp_enqueue_script

The best theme in WordPress theme development requires a standard protocol of enqueuing scripts through wp_enqueue_script, but this doesn't solve the problem and Google PageSpeed suffers. I found a ...
0
votes
1answer
95 views

Is there a better way to access transients using javascript

I've been searching around the web trying to find a better way to use wordpress transients with javascript. Currently I am using admin-ajax to run a php function that retrieves the transient and ...
0
votes
2answers
657 views

Get the current post ID as a variable in Javascript

I'm trying to echo the post ID in a post Javascript and not having any luck. var post_id = '123'; // works fine var post_id = '<?php global $post; echo $post->ID; ?>'; // echos 'ID; ...
0
votes
1answer
47 views

Javascript in plugin not working

I'm working on a plugin that relies on several JS scripts. In my plugin file (graph-plugin.php) I've the following function: function initialize_scripts() { wp_register_script( 'int-flot', ...
1
vote
1answer
29 views

Adding custom directory and PHP files in wordpress

I'm new to WordPress and I'm using the latest version. I am trying to add this library https://github.com/pinceladasdaweb/tweetlight which is getting the latest tweets from Twitter. Tweets should be ...