All Questions

Filter by
Sorted by
Tagged with
0
votes
0answers
14 views

Dequeue Parent Theme File and Enqueue Child's

Not being able to achieve this simple thing for some reason Parent Theme Code (File: css_js_include.php) if( 'estate_property' == get_post_type() || 'estate_agent' == get_post_type() || ...
0
votes
0answers
27 views

Override parent theme deregister

I have a parent theme that deregisters a script, in my case jquery. It does it like this: function parent_enqueue_scripts() { wp_deregister_script( 'jquery' ); [...] } However, in my child ...
0
votes
0answers
23 views

Scripts don't enqueue after removing plugin

Using the Ultimate Member plugin. My custom scripts are loading in my child-theme as follows: function some_theme_enqueue_styles() { wp_enqueue_style( 'parent-style', get_template_directory_uri() ...
0
votes
0answers
24 views

Jquery enqueued script in child theme not proccing

I created a child theme of the theme twenty-seventeen. I want to add some scripts, especially Jquery libraries and some custom Jquery to animate the homepage. This is what I have in functions.php (...
0
votes
0answers
147 views

Enqueuing multiple stylesheets with a child theme

I've successfully enqueued a parent stylesheet and child stylesheet. I'd like to enqueue a third - ultimately a style.php file, but a second-style.css would be a good start. It's not working for me ...
0
votes
1answer
691 views

Child theme stylesheet not always overriding “index”

I'm using a child theme and I'm using a "styles.css" file to override things from the parent theme. My styles (there are many stylesheets) are enqueued like this: function my_theme_enqueue_styles() { ...
0
votes
1answer
19 views

Javascript asset not enqueuing with the rest

I am working on a project that uses the child-theme's functions file to enqueue a stylesheet and a single javascript file. These two resources are enqueued well. However, when I add a new compiled ...
0
votes
1answer
612 views

Enqueue styles properly in a child theme and stylesheets location

I have inherited a site without a child theme and now we will have problems when it comes to update things. Everything in this theme was made on the main theme... I have now created a child theme but ...
0
votes
0answers
640 views

using a child theme, after enqueing my js file it is loading before jquery

I am new to wordpress as far as using a child theme and I have a my own js file that I need loaded. I have added this to my functions.php file: <?php function my_theme_enqueue_styles() { $...
1
vote
1answer
380 views

Is my child theme working properly

A few days ago I created a child theme of my theme zerif lite. Everything is looking good and there is no problem at all. I just want to know are the created functions.php and style.css files correct ...
0
votes
1answer
402 views

how to fix loading scripts in child theme?

I am trying to integrate an animation in my Wordpress home page, for this I am trying to load scripts from "skrollr" library, but my styles and scripts don't load. this is the code I added is ...
1
vote
1answer
1k views

WP .js script file not loading

I have looked all over the place and did not find a solution to my problem. I have a child theme where I have a functions.php file where I try to register and enqueue the script the following way: ...
1
vote
1answer
374 views

How to enqueue scripts in order of Head section

I have the two scripts that I need to enqueue. I'd like the child theme's script to be loaded after the Mustache template scripts. Even when specifying the priority, the child theme's script is loaded ...
1
vote
1answer
577 views

Cannot dequeue script in child theme

In functions.php of my parent theme, I have these function karuna_scripts() { wp_enqueue_script( 'karuna-functions', get_template_directory_uri() . '/assets/js/functions.js', array( 'jquery' ), '...
1
vote
2answers
72 views

Can´t access child theme´s scripts dependencies found in parent

I´ve been struggling with this for nearly a month now and still couldn´t find anything at all on how to do this! Not here, not in Quora, not through many different advanced Google search queries... ...
0
votes
0answers
48 views

JavaScript code do not works on online server

I am using a jQuery Image Zoom plugin (http://jacklmoore.com/zoom/) in my wordpress website. The matter is that it works fine in my local machine, but on online server don't work. The JavaScript ...
0
votes
1answer
34 views

how can I re-utilize and class on a child theme

I want to extend a class that is in a parent theme. For example, breadcrumb.php containing the class breadcrumb extended with a child theme file custom_breadcrumb.php with the class custom_breadcrumb. ...
0
votes
1answer
56 views

javascript not being enqueued correctly

I have the following in my child theme's functions.php: add_action( 'ors_enqueue_scripts', 'enqueue_parent_theme_style' ); function enqueue_parent_theme_style() { wp_enqueue_style( 'parent-style',...
0
votes
1answer
48 views

wp_enqueue wont work on some files?

So if i use the following in functions.php in the root off my child folder it works as supposed: add_action( 'wp_enqueue_scripts', 'register_my_scripts'); add_action( 'wp_enqueue_scripts', '...
0
votes
0answers
71 views

wp_enqueue_scripts doesn't work for template pages

In my child theme's functions.php I wrote : function add_js() { echo "path is : ".get_stylesheet_directory_uri().'/js/script.js'; wp_enqueue_script( 'script', get_stylesheet_directory_uri().'/...
0
votes
1answer
2k views

How to dequeue / deregister parent theme style

I'm making a child theme, and I'd like to remove the Google font style that it calls for in 'fonts-style' function nada_theme_styles() { wp_register_style( 'fonts-style', '//fonts.googleapis.com/...
0
votes
1answer
500 views

get_stylesheet_directory() in child theme breaks parent scripts

I tried hard finding another question that may answer my query but failed, so if you point any duplicates that would help. Here is my situation I have a parent theme and I am developing a child ...
11
votes
1answer
23k views

How to properly dequeue scripts and styles in child theme?

I made a parent theme and a child theme in one of my project. I enqueued CSS and JavaScripts in my parent theme like below: function project_necessary_scripts() { //Stylesheets ...
0
votes
1answer
1k views

wp_enqueue_style referencing parent theme

I have properly set up a child theme and am adding stylesheets and scripts in my new functions.php file. The only problem is, my newly enqueued stylesheets are being referenced using the parent theme ...
1
vote
1answer
3k views

How to create a child theme with multiple css files.

Noob at wordpress development. Trying to create a child theme for a client. But the problem is that there are many css files and not one as per many tut's available, in my senario there are multiple ...
0
votes
1answer
1k views

custom template - override plugin template in child theme - issue with scripts

I'm using a custom template for the single-listing.php from WP Listings. I've used my own theme (Canvas by woothemes) single post template, and included the wp-listings code. http://pastebin.com/...
0
votes
1answer
45 views

Overide enqueue in non plugable function via child theme

I am trying to override a non-plugable function using the information on this page but it seems to have no effect. Can anyone see what's wrong. My code is remove_action('wp_print_styles', '...
4
votes
2answers
1k views

jquery script not enqueued in child theme

I need a little bit of insight here with the following problem? I've created a child theme called 'test_child' which I am trying to extend in the following way: This is the test_child/functions.php ...
0
votes
1answer
341 views

css3-mediaqueries-js failing with child theme

Within my parent theme functions.php, I have the following snippet: // Add mediaqueries-js function footer_scripts(){ echo '<!--[if lt IE 9]><script src="http://css3-mediaqueries-js....
0
votes
1answer
211 views

Child Theme - what is the scope of overwriting files?

I noticed that creating twentythirteen-child/archive.php overwrites twentythirteen/archive.php but creating twentythirteen-child/shortcodes/drop-cap/drop-cap.php does not overwrite twentythirteen/...
0
votes
1answer
195 views

Modular CSS and JS in Child Themes

Let's assume that twentythirteen/shortcodes/ exists and inside are folders with shortcodes. 1 folder = 1 shortcode. Each shortcode has: 1 PHP file, 1 CSS file, 1 JS file. twentythirteen/shortcodes/...
1
vote
1answer
1k views

Including style.css in Child Theme

Twenty Thirteen uses wp_enqueue_style( 'twentythirteen-style', get_stylesheet_uri() ); in functions.php. Wheter I use it or not use it in twentythirteen-child/functions.php the style.css from Child ...
1
vote
1answer
157 views

Including files in Child Themes

Twenty Thirteen uses the following in functions.php: require( get_template_directory() . '/inc/custom-header.php' );. When I copy /inc/custom-header.php to twentythirteen-child, it isn't replaced. I ...
3
votes
2answers
1k views

Adding Custom Javascript to Skeleton Child Theme

I'm trying to register & enqueue ImageMapster in my Skeleton Child Theme on the main.php page to make an image map with hovering image effects. I added this code to the "Header Functions" section ...
32
votes
2answers
33k views

How do I dequeue a parent theme's CSS file?

My parent theme (Starkers) adds a CSS file that I'm trying to remove (I want to use @import instead so I can override styles more easily). Starkers has the following in its functions.php: add_action( ...
0
votes
1answer
1k views

Page not found when trying to link to files in child theme directory

I'm trying to create a child theme based on Toolbox 1.4 by Automattic. I have my scripts file saved as child_theme/js/scripts.js on my server and I enqueue it by using wp_enqueue_script( 'scripts', ...
35
votes
4answers
60k views

How to override JavaScript files in child theme?

I'm loading some JavaScript files in the parent theme. The path in the parent theme is: scripts > custom.js In the child theme, I'm creating the same path (scripts > custom.js) and changing ...
0
votes
2answers
4k views

How do I get a child theme to load scripts from the parent theme?

Pretty new to WordPress functions, so apologies if this is basic stuff. I've designed a parent theme that registers and enqueues two scripts like so: if ( !function_exists( 'scherzo_scripts' ) ) ...