Responsive site header img
-
I’m trying to make the site header img responsive for tablet and mobile but nothing I try is working…Please help
@media (max-width: 300px) {
.site-header .site-branding {
background: url(‘http://www.whenlifegivesyoulemons.com.au/images/lemon-logo.png’) 0 0 no-repeat;
float: none;
display: block;
-
Found the answer
#header_area {
background: url(‘http://www.whenlifegivesyoulemons.com.au/images/lemon-logo.png’);
background-repeat: no-repeat;
background-size: 100%;
}Hi there! Why are you using Custom CSS and not the built-in Custom Header functionality?
Because I don’t know WordPress very well and I’m not sure what your talking about where is the built-in Custom Header functionality?
you have confused me now!
I have now made a child theme for expound because I thought I was in trouble for changing css in parent theme and now the child theme won’t override any of the parent theme???
http://www.whenlifegivesyoulemons.com.au
i’ve also lost the site-header it’s not showing at all
.site-header .site-branding {
background: url(‘http://www.whenlifegivesyoulemons.com.au/images/lemon-logo.png’) 0 0 no-repeat;
background-size: 100%;
margin-top: 40px;
margin-bottom: 20px;
padding-right: 2px;
padding-left: 2px;
height: 200px;
width: auto;
}Upgrade the theme to the latest (1.5) which has Custom Header functionality.
Ok that is all working fine now but why isn’t my child theme style.css overriding the parent theme??
I have changed all instances of ##117bb8 which is the blue colour in the nav to #00666666 a green colour and no change has happened on the site?
Can I just change the parent css??
Don’t touch parent theme file or stylesheet.
Review this child theme documentation
http://codex.ww.wp.xz.cn/Child_Themesand fix the comment in the head section of your child
style.css, also remove out the copy over of parent style, leave in only@importline and start putting in changes down below it.‘fix the comment in the head section of your child style.css,’ ??? What am i fixing????
‘remove out the copy over of parent style’??? What does this mean?
This needs to be fixed.
@import url("../expound/style.css"); @import url("../expound/rtl.css"); /* Theme Name: expound Child Theme URI: http://www.whenlifegivesyoulemons.com.au/ Description: Child theme for the expound theme Author: Julie Small Author URI: http://www.julierenae.com/ Template: expound Version: 0.1.0 */ /* Theme Name: expound Template: expound */Your site is in English, and English is not rtl. Also, the default text
direction:rtlin thertl.csscan confuse browsers.There are 2 sets of
Theme NameandTemplate, we only need one.This
@import url("../expound/style.css");should be below that comment block. Make sure anything below this line only contain changes that you want.Ok so it now looks like this – Is this correct?? Cause it still doesn’t work??
And I just deleted the @import url(“../expound/rtl.css”); is that right?
/*
Theme Name: expound-child
Theme URI: http://www.whenlifegivesyoulemons.com.au/
Description: Expound
Author: Julie Small
Author URI: http://www.julierenae.com
Tags:*/
@import url(“../expound/style.css”);Try using the code that was posted above.
Huh????
Theme Name: expound Child Theme URI: http://www.whenlifegivesyoulemons.com.au/ Description: Child theme for the expound theme Author: Julie Small Author URI: http://www.julierenae.com/ Template: expound Version: 0.1.0 */ /* Theme Name: expound Template: expound */ @import url("../expound/style.css"); @import url("../expound/rtl.css");I already had that and was told it was wrong?
No – look again. The import lines have been moved.
The topic ‘Responsive site header img’ is closed to new replies.
