After Hours

General discussion


New to html and css. Needing help with background images.

By eladcire75 ·
Tags: Off Topic
I am new to html and css scripting. What I desire to do is to tag on image as a background image to cover the full full page, and another image on top (or to overlay the first one) so that I can have a little cleaner look and not worry with having sooooo much script in the html that confuses what I am looking at.

Here is the complete script as I have it thus far (without paragraph tags and other info that I plan to later add):

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<meta content="text/html; charset=ISO-8859-1"

<link rel="stylesheet" type="text/css"
<title>Two Guys Computer, Co.</title>
<body style="background-image: url(background_blue.jpg);">
<img style="width: 1080px; height: 1100px;" alt=""
class="center" src="background_two_guys.png"><br>

The styles sheet is as follows: { display: block; margin-left: auto; margin-right: auto; margin-top: 0px; margin-bottom: 0px;

I know that there is some piece that I am missing here. I have searched for a solution online but there is so much geedunk that I end up more confused rather than knowledgeable. That is to include what I have been reading on the W3C Schools site. I have found that some things just don't work, especially across browsers.

I would like to control every aspect of the background image through my stylesheet though this seems to be the only way that I can get the images to display even halfway properly. At the moment the background_blue.jpeg displays perfectly. The other image centers properly but it doesn't span the page fully from top to bottom. (Please realize that I am extremely new to this subject and that I appreciate enlightened discourse rather than what I have experienced on other forums.)

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Comments

Collapse -

HTML not really showing up.

by eladcire75 In reply to New to html and css. Nee ...

I don't know what exactly happened but the html script didn't really show up. What I have actually done is just to edit the background photo to overlay the photos. I think that it looks fairly sexy. Anyway I am working on a conditional statement that will force IE9 to read my style sheet (external style sheet). I haven't like IE for a very long time, but I understand that lots of people still use that browser. Any suggestions to help out with it? This is the conditional statement that I have attempted to use, but have had no luck in getting this to work.

<!--[if IE ]>
<link href="iecss.css" rel="stylesheet" type="text/css">

IE takes me to my wits end trying to debug it. I would actually like to target all of the IE versions with one statement rather than to target each one. I don't plan on using too super much of the higher end script.

Related Discussions

Related Forums