Is there any way to make a background image stretch rather than repeat?
Share
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.
Not using any kind of cross-browser compatible CSS (there is the
background-sizeproperty however.)If this is directed at any browser in particular, it might be possible. Otherwise, you’ll need to use an
<img>and stretch that.Here’s how you do it in recent browsers:
Otherwise, using an
<img>: