WordPress.org

Ready to get started?Download WordPress

Forums

raindrops
[resolved] Child theme and style (3 posts)

  1. Luigi Rosa
    Member
    Posted 5 months ago #

    Hi,
    I am using raindrops as a master theme for a custom child theme for my blog.

    Raindrops embeds some styles in the HTML generated code (<style type="text/css" id="raindrops-embed-css"> container), so I cannot override the settings in the embedded style.

    Is there a way to override that CSS ina achild theme?

    I am now trying to override the background colour of comment boxes, but I will need to override other styles.

    How can I do this without modifying the raindrops files?

    Thank you!

  2. nobita
    Member
    Theme Author

    Posted 5 months ago #

    Hi lrosa
    You should use strong Specificity CSS rules

    Override with CSS example below.

    #comments a{
    	color:blue;
    }
    #comments form{
    	background:yellow;
    	color:black;
    }
    #comments input[type="submit"]{
    	background:red;
    }
    #comments #respond textarea#comment{
    	background:green;
    }

    if you can use PHP Script

    Raindrops can Create a your own Color Type.

    for example

    Add to functions.php at child theme

    add_action( 'after_setup_theme', 'child_theme_setup',11 );

    <?php
    function child_theme_setup(){
    	raindrops_register_styles("original");
    
    	function raindrops_indv_css_original(){
    	$font_color = raindrops_warehouse_clone('raindrops_default_fonts_color');
    	$style=<<<CSS
    	a{color:yellow;}
    	body{background:#000;color:#fff;color:$font_color;}
    
    CSS;
    	return $style;
    	}
    }
    ?>

    function name needs raindrops_indv_css_ + color type name

    If you add this code, you will be able to choose customizer and theme options page, a new original color type

    Thank you.

  3. Luigi Rosa
    Member
    Posted 5 months ago #

    Than you for your kind answer!

Reply

You must log in to post.

About this Theme

About this Topic

Tags

No tags yet.