Hey,
Someone know how to make auto size background image for child theme ? Already had search in google for some tips, but nothing usable...
Hey,
Someone know how to make auto size background image for child theme ? Already had search in google for some tips, but nothing usable...
Have you tried the background-size property?
I don't find where is css with "body.custom-background {"
Use a Browser Inspector Tool to easily find which elements have which styling.
Yes. I'm using it. But in style.css dont find it:
body.custom-background {
background-color: #F2836B;
background-image: url('http://www.website.com/wptest/wp-content/uploads/2012/11/background.jpg');
background-repeat: no-repeat;
background-position: top center;
background-attachment: fixed;The browser inspector tool should be enough to see the CSS styles applying to the element. You should then override or add-to these styles in your Child Theme style.css (create new code). You shouldn't modify current code in your parent theme's files.
Yes I know it. But anyway background don't auto fit with browser size.. I need to see background nice with aspect ratio in any resolution. Default img aspect ratio 16:9, in 4:3 resolution img can be centered, but hidden left and right sides..
Perhaps this tutorial will help.
I don't know how it is possible, but I cant find from where it's generated:
It's probably generated by a plugin, but why are you concerned with this?
Because I don't know where to put code from your link to tutorial.
You should add it to your Child Theme style.css file (stylesheet).
Everything was fine but, need to insert
<div style="max-width:500px;">
<img src="..." />
</div>
Where put this code ?
I think that code is the equivalent of the code you added in style.css. You need not add it.
I don't know but it doesnt work for me.. :/ Too noob to make it.
What code have you added into style.css, from the tutorial?
Hello,
I use in style.css:
html {
background: url(images/background.jpg) no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
Remove background image from menu and leave some bg color, because if I remove color, borders in each side dissapier.. So I have problem, website show color, but with dev tools if I remove bg with color, my img shown correctly..
Is this a separate issue?
WordPress overwriting my image with Backround Color in WP Appearance options..
Yes it's seperate.
As this is a separate issue, create a new thread for it. This will increase the likelihood of receiving help.
You must log in to post.