I've created a custom child theme of parent theme Cordillera.
This is my child theme's header.php (<head>
):
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<?php wp_head();?>
<?php
global $enable_home_page;
$banner = "";
$home_banner_type = cordillera_options_array("home_banner_type",1);
$enable_home_page = cordillera_options_array("enable_home_page");
if( is_front_page() ){
$class = "homepage";
$banner = cordillera_get_banner($home_banner_type);
}
else
{
$class = "sitepage";
}
?>
<link href='http://fonts.googleapis.com/css?family=Waiting+for+the+Sunrise' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'>
<?php if(!(is_front_page())) { ?>
<!-- non-front-page CSS -->
<style>
html {
background-color: transparent;
background: url('<?php echo get_stylesheet_directory_uri(); ?>/images/bg-product.jpg') no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
<!-- END non-front-page CSS -->
</style>
<?php } ?>
<?php if(is_page(6)) { ?>
<!-- shop page CSS -->
<style>
.blog-main {
background-color: transparent !important;
}
</style>
<!-- shop page CSS -->
<?php } ?>
</head>
I haven't included a link to my child theme's style.css
in this file, instead using:
add_action( 'wp_enqueue_scripts', function() {
wp_register_style( 'childstyle', get_stylesheet_uri());
wp_enqueue_style( 'childstyle', get_stylesheet_uri());
});
in my child theme's functions.php
.
However, when logged into Wordpress admin, and viewing WooCommerce pages, some of the admin tool bar links are being colored by my child theme's style.css
.
How can I prevent this? Thanks.
!important
declaration, such asa { color: #0066FF !important }
— so please check your theme parent stylesheet and child theme stylesheet for any similar styles. – Adam Jul 31 '15 at 10:00