A client side scripting language useful for making interactive web sites
1
vote
1answer
28 views
JavaScript && operator in visual editor
I am used to of adding javascript/jquery code in posts via visual editor but it seems I never used && operator cause wordpress is altering && operator in &. Here is a link where I ...
0
votes
1answer
130 views
Multisite configuration fails with css/js files
I have installed Wordpress using multisite + path (as opposed to subdomain).
Seems to work, except JS/CSS files are not loaded.
my conf:
<Directory "/var/www/pages">
Options All
...
0
votes
3answers
526 views
wordpress wp_enqueue_script() not working
I'm trying to add this social-network button:
<a href="http://svejo.net/submit/?url=[your url]"
data-url="[your url]"
data-type="compact"
id="svejo-button">Add in Svejo</a>
...
0
votes
0answers
12 views
One page site (returning from google) + history manipulation
I am making a one page site using wordpress.
The one page has all the menu pages linked into one, but there will be arbitary pages (landing pages) for subcategories and stuff at the moment.
I have ...
0
votes
1answer
20 views
Replacing WordPress Icons (menu,icons32, etc)?
I want to replace wordpress admin sprites. I recreated the images and looked answrs for icon replacement using jquery and simply with CSS BUT what about ones link icons32-2x.png where I can't find the ...
0
votes
1answer
21 views
Covert Wordpress Blogname into JQuery
Here is the blogname in php <?php $blog_title = get_bloginfo('name'); ?>
I want to convert it to javascript. The file I want the blog name is in a .js file so I cant create the variable with ...
9
votes
2answers
253 views
Does the functions.php file ever get called during an AJAX call? Debug AJAX
Trying to figure out an issue a fellow programmer is having. I was wondering if the functions.php file get called at all when you do admin side AJAX? I know that when you do an AJAX call a part of ...
3
votes
2answers
946 views
How-to implement admin Ajax inside an admin WP_List_Table?
I am new to WordPress if someone will help me I will be very appreciate.
There is parameter ajax "true" but in docs. wasn't said how to implement Ajax using WP_List_Table Class?
parent::__construct( ...
1
vote
1answer
30 views
Display the number of unseen comments on a page since the user last visit
The community is private and it has several pages /wordpress /design /etc . When users go to those pages the only thing they can do is to comment.
Now, what I am trying to do, Idk if possible, but if ...
-1
votes
0answers
14 views
thickbox.js Endless loading gif. Why is thickboxL10n not defined?
Below is the line that throws the error. I am using thickbox.js
jQuery("#TB_window").append("" + ""+caption+"" + TB_imageCount + TB_PrevHTML + TB_NextHTML + "");
0
votes
0answers
15 views
Lightbox Post Pop-up on homepage [duplicate]
I've been working on sampression lite theme and what I want to achieve is when a post' thumbnail/read more link on homepage is clicked, a modal will pop-up ( similar to pinterest and this wp theme ...
0
votes
0answers
11 views
How to utilize theme customizer live preview in this situation?
Short version: I am using the theme customizer in my theme and javascript for the live preview. I am not sure how to implement the javascript for php(as seen in code excerpt).
I am creating a theme ...
0
votes
1answer
223 views
Placing Ads after every 10th Post with Infinite Scroll
Hello at the moment what I have to do is load a couple of ads, some normal html and two are java script. I've tried the PHP method of this:
<?php $postnum++; if($postnum%10 == 0) { ?>
<div ...
0
votes
1answer
17 views
Loaded JavaScript file not showing [duplicate]
I'm working a custom WordPress site, and I've loaded all the required JavaScript file:
wp_enqueue_script('easing', get_stylesheet_directory_uri() .'/js/diapo/jquery.easing.1.3.js');
...
-1
votes
0answers
21 views
Hyphens are causing a blank result
I'm having issues with hyphens in my slugs from a tutorial I'm trying to go through... http://wp.tutsplus.com/tutorials/theme-development/create-a-quicksand-portfolio-with-wordpress/ and I'm having a ...
0
votes
0answers
34 views
how to retrieve subcategory related to category in edit page from view page by using javascript
I am doing a basic product page by using JavaScript,php and html. I retrieve the category related subcategory drop down list from view page .but my subcategory is not change according my category .I ...
0
votes
1answer
236 views
Ajax URLs without #!, how to prevent falling into single.php on load or reload?
I'm trying to make things properly with a single page ajax powered portfolio. I've read that there is no need of #! to make it crawlable by google. So I have clean URLs that updates with .pushState ...
0
votes
1answer
139 views
How to add a onclick attribute to a list of checkboxes?
I have this array for checkbox:
array(
'name' => __('Latest Product',''),
'desc' => __('Select if you want to display latest product',''),
'id' => $prefix . ...
0
votes
1answer
195 views
Add multiple JavaScript files to template header [duplicate]
I have multiple JavaScript files that I want to load. Some of them in my header.php and the rest in the footer.php.
These are the files:
<?php
<script type="text/javascript ...
0
votes
0answers
10 views
PressThis works inconsistently in Safari
... and this has been true for several years and several OS X versions, just haven't found any answer.
On the other hand, my Tumblr bookmarklet has worked 100%, through all this. Or maybe they're ...
1
vote
1answer
40 views
How to deal with the confliction between PHP-Markdown and MathJax?
I use PHP-Markdown plugin in WordPress. In order to show the formula beautifully, I add some code to use MathJax.
Like this:
<script type="text/javascript" ...
0
votes
0answers
19 views
videopress videos are not displayed when loading the content with ajax in a lightbox
I'm using videopress and I'm adding the videos into posts with the videopress shortcode, and when I visit the post I can see the videos and play them, but the problem is when loading the post with ...
13
votes
1answer
256 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 ...
0
votes
2answers
937 views
Add captcha validation to my custom form for Frontend posting
i have implemented the frontend form, which enables UNREGISTERED users to post on my site.
Everything in working perfectly, the only problem I have is with the implementation of the captcha.
All of ...
1
vote
2answers
83 views
Load multiple Javascript scripts
I have three Javascript script that I need to load -
imagesLoaded.js
lazyload-1.8.4.js
and cd.js
cd.js contains my functions that use imagesLoaded.js and lazyload-1.8.4.js.
Do load them ...
3
votes
3answers
134 views
How can I reduce the amount of files loaded/included per plugin?
I have a Wordpress site that uses several plugins, namely 8. Most of these plugins include a lot of their own JS and CSS files, some even include so much as 3 separate CSS files. One can imagine that ...
2
votes
2answers
447 views
How to control contextual help section by code?
I had added some content to contextual help section for plugin options page.
Now I'd like that page defaulted/toggled to contextual help section open on specific condition in my PHP code. My only ...
0
votes
1answer
50 views
What can cause JavaScript and CSS files to be minified?
On one of my client's site, I see that my plugin's JS and CSS files are minified.
Trying to identify what causes the files to minify, I tried to deactivate all plugins (except mine), and changing the ...
0
votes
1answer
111 views
Cloudflare's Rocket Loader + Wordpress -> Ignore scripts?
I'm trying to make Cloudflare's Rocket Loader work on my WP site. Everything works fine except for the WP Visual Editor. I followed the advice here but it doesn't work:
How do I add custom attributes ...
1
vote
1answer
177 views
prettyPhoto media loading very slowly in Chrome
I'm having a problem with prettyPhoto media WordPress plugin (lightbox type) script in Chrome. It works beautifully in other browsers, but it takes forever to load in Chrome.
When using this script ...
0
votes
1answer
58 views
How to Load Plugin JS in theme's footer section
I am working on optimizing my theme so that the load time can be decreased, as of now i have used wp_enqueue_script() to add my custom js file and everything is working fine as expected.
One thing ...
0
votes
0answers
3 views
Having a hard time getting Javascript to work in a post. Please help [migrated]
Disclaimer: I know nothing about javascript.
I'm trying to get this script to work on the test post. The goal is to have the links below the video jump to certain spots in the video. It works fine in ...
0
votes
1answer
26 views
website script stopped working
i have 2 copies of my wordpress website one online and the other offline the code now is working on offline but on the online some scripts stopped appeared when i used contact 7 plugin but i fixed it ...
0
votes
2answers
183 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
0answers
57 views
Single page site with history.js
I'm developing a single page site that shows each page on the front page, like so:
*-----------------*
| Home |
...
0
votes
0answers
25 views
get_option include <br /> in my adsense
As title said I saved in wp-options -> option_value a adsense code but when I try to display to website in the code I get some
"<script type=\"text/javascript\"><!--<br ...
0
votes
1answer
241 views
How to make featured image thumbnails on index page load smoother?
I'm using a theme called Hatch Pro, which is a gallery based theme and the index page displays the posts using the featured image. You can see it here.
On slower browser environments, the images ...
0
votes
1answer
406 views
Want to add comments to NextGEN Gallery
Does anyone know how to do it?
I would like to implement Facebook or Disqus comments.
I am using the gallery with the shutter effect.
Thanks for your help!
2
votes
3answers
1k views
Comment Reply javascript
I am working on a client site which is a very stripped down theme. It has no standard html markups as a result of which the reply box doesn't move upto the place of being just below the comment to ...
0
votes
1answer
132 views
Ajax Validation for reCaptcha
Background
I have a registration form that validates with AJAX using jQuery Validation Engine. The form was created using Theme My Login and contains reCaptcha which I implemented using WP-reCAPTCHA.
...
3
votes
4answers
11k views
jQuery UI Datepicker not working
i want to add a datepicker on a custom page but i doesn not work. WP version is 3.2.1.
Those are the init string i used on wp code:
wp_enqueue_script('jquery');
wp_enqueue_script('jquery-ui-core');
...
0
votes
4answers
43 views
contact 7 plugin stops some pages from working properly
I started to use contact 7 plugin and I'm having a slider and some effects on other images when i activate the plugin they stop working this is the web page
http://www.digitalways.com.sa/
I ...
0
votes
1answer
46 views
wp_deregister_script was called incorrectly
So apparently I am now allowed to do the following in the admin, ON my theme options page and only ON my theme options pages:
public function load_admin_jquery(){
...
0
votes
1answer
35 views
How to enqueue some javascript source once per page
I need my plugin to generate the following - once per page:
<script type="text/javascript" src="https://<ritc url for js file>"></script>
<script type="text/javascript">
...
0
votes
1answer
30 views
Screen Options JavaScript Code
I want to know, what script drives the "screen options" animation toggle in WordPress.
I'm referring to the options menu that slides out when the admin clicks the "Screen Options" link near the ...
1
vote
2answers
47 views
How do I only load js on the post-new.php and post.php pages in admin?
I have some script that is loading in the admin. I only need it to load on the new post and edit posts screens.
What is the best way to do this?
32
votes
3answers
8k views
What is the preferred way to add custom javascript files to the site?
I've already added my scripts, but I wanted to know the preferred way.
I just put a <script> tag directly in the header.php of my template.
Is there a preferred method of inserting external or ...
0
votes
1answer
36 views
Linking wp_enqueue can't find the javascript file (adds “?ver=x.x.x” to the src)
So I'm trying to link in a javascript file the right way, by using this:
--functions.php--
function custom_scripts() {
wp_register_script('myscript','/backdrop.js',array('jquery'));
...
0
votes
1answer
31 views
Plugins not showing up for custom template
I'm customizing the index.php page. I've customized my header.php and footer.php and created the styles for both things.
My main index.php page has:
<?php
/*
Template Name: Main
*/
?>
...
0
votes
0answers
32 views
Created custom control from theme customizer, where should I add code it will control?
I have created a custom control for the theme customizer which is a simple button and label. I am going to be using it as a theme reset button that will clear the theme mod settings to their original ...