A client side scripting language useful for making interactive web sites

learn more… | top users | synonyms

0
votes
0answers
54 views

WordPress & iDangerous Swiper

Sorry to bother you with whats probably an easy thing: I came across a nice carousel created by iDangerous that I would like to implement into a WP theme. Do you guys have any suggestions on how to ...
0
votes
3answers
55 views

Wordpress text widget with onclick function

I have a text widget, in it i just place there an iframe. A few days ago i wanted to override this widget on mobile browsers and add a background of an image on mobile browsers, luckily i used How to ...
1
vote
1answer
108 views

Refused to execute script from '***' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled

I am facing some UI issues with my wordpress website. The newly added "Author" role is not able to see the formatting toolbar while writing the post. After debugging, I found a javascript error which ...
0
votes
0answers
63 views

How to include jQuery and JavaScript code in metabox?

I am trying to include jQuery and JavaScript code in a metabox but it is not working. Can anyone give a suggestion how I can achieve this? function prefix_enqueue_scripts3() { ...
0
votes
0answers
71 views

add attachment-filters on custom modal-media insert

how can I do to have the attachment-filters menu in my upload window? my upload wordpress deafult upload console.log("enqueque on metabox.php - media3.js"); openMedia = { data: false, v: ...
0
votes
1answer
66 views

Why I'm Not Having Access to “$_POST” Data Outside My AJAX Callback?

I'm trying to pass some data from the Back-end to JavaScript. The thing is, when I try to console.log() the variable passed through the wp_localize_script() it shows me on Console the structure that ...
0
votes
1answer
102 views

Divi theme including javascript

I have tested the html and the css and the js independently of wordpress and all works fine. So trying to integrate it into wordpress. I have added the html code as a code module. I have created a ...
0
votes
1answer
60 views

Custom AJAX form not working async

I have a contact from that uses PHP mailer that I have integrated into my Wordpress blog. The script sends emails no problem - the issue is that it does not work async so once the form is submitted I ...
0
votes
1answer
24 views

About a programming language starts with <# #> [closed]

Is that a Javascript code?? The following code inside a php class file but after closing php tag start these lines and the [data] variable not defined in this class i want to trace the [data] ...
0
votes
0answers
124 views

Create new product with woocommerce REST API with javascript (clientside)?

Is it possible to create new products in woocommerce using its API with javascript from clientside? I tried this for getting all products: endpoint: ...
1
vote
1answer
50 views

How to select the contents in the text view textrea in wp_editor?

I am trying to count words among other text stats entered into the default post editor (wp_editor). Its supposed the write word count out to <div id="word count"> in the meta box immediately ...
1
vote
2answers
52 views

Creating a Multi-Level Associative Object Using AJAX

I'd like to create a Multi-Level Associative Object on $.post method using WordPress, in order to make my code cleaner. The problem is, I don't know how to get those values to manipulate on the ...
0
votes
1answer
45 views

comment-reply.js disables any other form javascript

I want to add autosize.js to the form textarea (#comment) but if comment-reply.js is enabled no other javascript in the comments form works. Any idea why is this happening? //Auto resise textarea ...
-4
votes
2answers
59 views

Browser is showing Javascript code instead of processing it [closed]

Currently I've tried this process with two browsers: Google Chrome and Mozilla Firefox. Whenever I want to run a JavaScript code on them they show me the raw code instead of executing it. Exactly what ...
0
votes
1answer
40 views

WP adds long version query strings to CSS and JS files

I noticed WP adding long query strings to my CSS and JS files. Not just the version parameter from wp_enqueue_style from a Theme or something, no something fishy going on. I even switched to the 2016 ...
0
votes
2answers
67 views

Jquery window.send_to_editor function

I have created a metabox to upload images. Whenever I click on the "Select Image" button the Image Uploader Box successfully pops up but when I select an image and click the "Insert" button the image ...
0
votes
0answers
22 views

CSS and JS includes are staying HTTP after changing site to HTTPS

i have setup an SSL cert for my domain and its working correctly for everything other than wordpress. All other PHP apps are working fine, but i cant seem to get wordpress to include any CSS or JS ...
0
votes
1answer
112 views

JS file is not loading when i put wp_head() and wp_footer

In my WordPress project I need to use a WordPress plugin, For that plugin to work I have to put wp_head() and wp_footer(). But when I put that than my slider's JS file don't load. <script ...
0
votes
0answers
31 views

Refresh the Customizers preview after editing fields

I'm using ACF fields on a few custom widgets. While using the Customizer to edit fields, they will save on change but the preview will not refresh. Calling wp.customize.previewer.refresh() will ...
0
votes
1answer
38 views

How to run JavaScript function in WooCommerce checkout?

I'm building reCAPATCHA into my WooCommerce checkout. It is a fairly easy process as I'm using woocommerce_checkout_process to validate the capatcha. However, I have running into one issue. When ...
0
votes
2answers
96 views

Enqueue Javascript After ALL Other Scripts (Including Async Scripts)

I have a script I'd like to include with Wordpress. This script relies on another (prettyPhoto) to run, as well as on JQuery being loaded. I'd like my script to be the very last script to be included ...
0
votes
0answers
50 views

Onclick Save Text In Input Field

Currently, I have a front-end form on my client's wordpress site that allows users to create a post. I'm using the pods plugin to create cpt, custom fields, forms, etc. I have several input fields in ...
0
votes
0answers
23 views

Connecting a wordpress site to an AngularJS APP

Currently I have a application that needs a blogging system added. The application is built with an AngularJS front-end and a python/Django back end. I wanted to use wordpress as the blogging system ...
0
votes
0answers
20 views

media image not showing after adding ajax google api

I have added a script in my header.php and ajax file <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script> <script>....</script> But due ...
1
vote
4answers
82 views

Need a method for base_url() or home_url() in CF7 additional settings [closed]

For a redirect in CF7, on_sent_ok: "location.replace('https://www.mywebsite.com/pageid')" works well in the additional settings but I need to make my website more portable. I would like to use a ...
1
vote
1answer
50 views

accessing wp.media api from a tinymce plugin

I'm trying to create a tinymce plugin that generates a shortcode containing two image ids: [image-fade old="xx" new="yy"] I would like to let users select images directly from the media selector ...
-2
votes
1answer
26 views

Get current day using javascript [closed]

I'm trying to get the current date using JavaScript. Is it possible to do that? I want to add classes to some DOM element and it depends of the day of the week. Which element should I add to this ...
4
votes
3answers
645 views

Remove extra Google Maps script

I'm developing a plugin that use a Google Maps API. The plugin enqueuing script in this way: wp_enqueue_script('google-maps', ...
0
votes
0answers
43 views

Customizer Api: Load settings and controls from dynamically generated array

I have a front_page setting like so: $wp_customize->add_section( 'front_page', array( 'title' => __( 'Front Page' ), 'priority' => 120, ) ); I am trying to allow the user to do ...
0
votes
2answers
48 views

Disable submit button order

Here is a snippet of my code <?php echo apply_filters( 'woocommerce_order_button_html', '<input type="submit" class="button alt" name="woocommerce_checkout_place_order" id="place_order" ...
0
votes
1answer
45 views

How to capture a variable query string, then append it to all URLs in a Wordpress site

I have a site in which people will be sent there with various promo code query strings (that will change all the time), i.e., www.example.com/?source=emailad How would I capture the query string, ...
0
votes
0answers
46 views

Can't change javascript files

I've deleted a javascript file from my server, but it appears to still be there when making requests to the web server. I made a GET request with cUrl to the specific .js file to make sure there ...
1
vote
0answers
105 views

PHP array to JS array to use in google map

Hi I want to use some data stored in a php array to use it in google map api, to populate multiple locations in a the map. I use the loop to create my php array. <?php while ( ...
-1
votes
1answer
56 views

WP site makes mobile browser crash for high memory usage

I have this site: http://theguiltycode.com It uses foundation as a theme and is hosted in bluehost. I can load the site without much problem in desktop browsers, but in mobile the site reloads like 3 ...
0
votes
1answer
69 views

WP Media Uploader modal conflicts with Bootstrap modal

I was creating a form in a Bootstrap Modal to allow users to create new posts from the frontend. Everything seemed alright until I wanted to upload a file to the media library or choose one already ...
0
votes
0answers
64 views

Extending TinyMCE to Work with Medium Editor

I'm trying to extend tinyMCE. What i'm trying to achieve is to use this Medium Editor extend tinyMCE functionality as buttons within the backend Page / Post / Custom Post Type. This is similar to ...
0
votes
0answers
33 views

How to fill up in tags?

i have some problem to fill up the data Here is my code $.getJSON( url + input + "/keywords?" + apikey, function(tmdbdata) { $.each(tmdbdata, function(key, val) { if(key == "keywords"){ ...
0
votes
1answer
53 views

I need help implement a Javascript code into the PHP file

I need help implementing a Javascript code into my PHP file that would replace the default search box with a new one. Do I have to use echo? How would it look like? Thanks in advance or your help, ...
0
votes
0answers
19 views

How to hide a Control in the Customizer?

I know contextual controls hide if for example the user navigates from the viewer certain pages. But how can I achieve hiding a control under this scenario: There is a type Select Control with an ...
0
votes
0answers
49 views

how to make video autoplay on website in mobile using revolution slider

I understand that the video can't be played on mobile devices because of the ruling of the mobile data and other requirement. i also read comments on other articles on support. but i read some ...
0
votes
1answer
60 views

JQuery and Javascript to pan image

I am trying to implement a panning effect on an image, by following this tutorial. However, it's not working and I think it may be due to the way the javascript is being referenced. The image that I ...
0
votes
1answer
65 views

How to integrate a JS fiddle?

Dear StackExchange community, My goal is to add a second horizontal scrollbar on a very wide HTML table. I have downloaded a JS file recently that I wanted to use it on my website: ...
0
votes
1answer
38 views

Simple JS function Not Working

I have been trying to get a simple JS function to work for the longest while but its just not working. Console says "test is not a function. echo '<input type="hidden" ...
1
vote
1answer
39 views

Show post in slider

I am working on wordpress project .I want to show the post details in such away that the first four post thumbnail would show on the top and show the content of first post below, after clicking on ...
1
vote
1answer
44 views

Storing posts from query and accessing later via AJAX call

To clarify the above question title, what I am trying to do is create a grid of posts, for which I am displaying a thumbnail of an image that is attached to that post. Then, upon clicking each of ...
0
votes
1answer
274 views

wp.template() Not a function

When I console.log(wp) the object only includes: -wp.emoji -wp.heartbeat -wp.svgPainter Script is loaded in the footer and last in the DOM. What am I missing?
0
votes
0answers
18 views

add <script data-pagespeed-no-defer> in wp_register_script function [duplicate]

I’m using PageSpeed on my website and it makes a huge speed difference in my website I have defer JavaScript on. And I’m facing an issue with a script that doesn’t work when deferred so I want ...
0
votes
1answer
50 views

Add a downloaded JS file to WordPress

I have a very large table (horizontally speaking) on my webpage and I added a scrollbar using the "overflow-y: auto;" property on my CSS, which does what I want. The problem is that this table is ...
0
votes
1answer
21 views

javascript not loading

Here is what I've done so far in functions.php function imk_scripts() { wp_enqueue_script( 'bootstrap_js', get_template_directory_uri() . '/js/bootstrap.min.js', ...
1
vote
2answers
273 views

How to use WordPress (PHP) functions in AngularJS partials files?

I am using AngularJS to load a list of my WordPress posts, however I can not get any of my PHP functions to work with my partials file. I've tried using something such as search.php instead of ...