Tag Info

Hot answers tagged

2

It could be a configuration setting stored outside the files, and in the database instead. Using phpMyAdmin from the control panel of your host, Export the database, then open the SQL file in a text editor and search for the string. https://support.hostgator.com/articles/specialized-help/technical/exporting-a-mysql-database-via-phpmyadmin I assume you've ...


2

The stylesheet is registered and enqueued by a function called twentyfourteen_scripts() in the theme's functions.php. Callbacks hooked into the style loader/dependency system will be echoed on the wp_head action in the wp_head() function. Which, by the way, is how you should be loading your own stylesheets. There is a similar system for scripts.


2

In short: make sure that the Jetpack plugin is installed and enabled, and also that the Jetpack Lite plugin is not enabled. I found out that Edit CSS is provided not by WordPress itself but by the plugin Jetpack. Jetpack was still installed; I had a Jetpack menu right below Dashboard. But when I opened it, I saw only two items, “WordPress.com Stats” and ...


2

You can use wp_add_inline_style(). Let's assume you enqueue your css like so add_action( 'wp_enqueue_scripts', 'add_my_style' ); function add_my_style() { wp_enqueue_script( 'my_style', get_template_directory_uri() . '/mystyle.css' ); } Then you can change the function like so: function add_my_style() { wp_enqueue_script( 'my_style', ...


2

functions.php unfortunately is very ingrained part of theme load process. If your architecture is flexible enough you should be able to conditionally unhook related bits. Even if it's not — templates give you complete control over page output. You could go as far as completely omitting wp_head()/wp_footer() calls and handle assets (semi-)manually if that is ...


1

This can easily be done with body classes and conditional statements. Looking at your question, you will have a custom 'page.php' and 'single.php' for what you are doing. For this purpose, I'll call them 'page-custom.php' and 'single-custom.php' We can now assign a body class to these pages with the following function function mytheme_body_classes( ...


1

I'll try and answer this for you based on the limited information you've provided... When using woocommerce, you also need to define the various image sizes for your products in the dashboard at Woocommerce > Settings > Product Image Sizes Whatever size you choose should match the sizes in your Media Library settings, but you've already said that these are ...


1

Inspect the global variable $pagenow, and use post_type_supports() to find post types with an editor: function has_post_editor() { global $pagenow; if ( empty ( $pagenow ) ) return FALSE; if ( ! in_array( $pagenow, array ( 'post-new.php', 'post.php' ) ) ) return FALSE; return post_type_supports( ...


1

Having template files in different folders has nothing to do with styles not working. View page source and make sure the right stylesheet is loaded. If its loaded, then double check if there is any other rules thats overriding your needed rules for specific class. Try adding !important to the css definitions and see if it works. This is how you should ...


1

To be honest I think you can just use some custom css to get the job done. Wordpress gives the homepage a custom body class of home. so if we use that and dig down in the css to the first menu and move it over into view you should be good. .home .menu > li > ul { left: 0; } and to get the hover state on the 'Data' link just use .home #header .menu ...


1

I wonder if you are looking for the style_loader_src filter? For example: add_filter( 'style_loader_src', function ( $src ){ // ... your stuff ... return $src; } ); Similarly there exists the script_loader_src filter. There's also the base_url property of the global $wp_scripts and $wp_styles objects, but I think that's only ...


1

It may be time to learn how to use Child Themes. Takes less than 15 minutes to learn, saves huge amounts of time. It could be as simple as creating a style.css and giving it the proper the title info at the top of the file. See https://codex.wordpress.org/Child_Themes#How_to_Create_a_Child_Theme Using a child theme is like laying magic tissue paper over ...


1

Quick steps to identify exactly where it's coming from: 1. comment out wp_head(); in your header.php. If this removes the Google Fonts call then look through your active plugins and the theme (parent and child) functions.php files 2. deactivate plugins one at a time 3. swith to twentyten or similar theme Depending on which of these steps removes the line ...


1

There's probably a few ways you could go about doing this: Method 1) Enqueue your styles after theme styles - View Codex Method 2) Use !important which will take 100% precedence - View Stack Overflow Method 3) If you're creating your own widgets you can insert your own <style> tags which will take precedence over any external files - View Stack ...


1

Is possible to make bootstrap css "contextualized" inside a selector, i.e. bootstrap styles works inside that selector, and thanks to css specificity rules, there them take precence over other rules. How to do: First of all download bootstrap less. Let's assume that this files are in 'bootstrap/less' folder. Now create a new less file, let's assume ...



Only top voted, non community-wiki answers of a minimum length are eligible