Solved

CSS question: how to stretch an image to full screen width

Posted on 2015-02-20
3
88 Views
Last Modified: 2015-02-20
I've been having trouble with this one. I need to stretch an image to the full width of a screen, no matter what screen resolution. I am pretty sure I can do that with CSS.

Here is the web site: http://www.leafyhead.com/

In the header area you can see the logo image. I'd like to stretch that image to whatever the width of the screen is.

Does the image need to be a background image?

Is there a CSS style that will do what I need?

Thanks as always for your help.

Eric
0
Comment
Question by:Eric Bourland
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 500 total points
ID: 40621604
Just use background-size:cover for the CSS of the element where you are using it.

Cd&
0
 
LVL 3

Author Comment

by:Eric Bourland
ID: 40621613
Got it. I was looking for that. =) I'll go try it now. Thank you!
0
 
LVL 3

Author Closing Comment

by:Eric Bourland
ID: 40621701
Thanks for pointing this out to me. =)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When applying CSS to your HTML, there are many different ways to select which element(s) the CSS applies to.  Some of these selectors are more commonly known and used than others - Here are the more common ones: #X - Matches an ID of X .X - Matche…
CSS is a visual language used to classify objects and define rules about how they should be displayed. CSS skills aren’t restricted to developers anymore, there is a big benefit to having a basic understanding of the language, regardless of your occ…
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question