I want to use background image and color for the same element
but id doens’t work even I use the css like this question
here’s my css
http://jsfiddle.net/xdkwB/
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Your CSS is working correctly, both the image and background colour sit within the one container so because they’re the same colour, you can’t actually see the arrow.
The best way to solve this is to use an outer div that wraps your header element, like so:
And then style with appropriate CSS:
So to clarify, the outer div is slightly larger and contains the background image aligned to the left and then the header fills all remaining space with the background colour.