INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

CSS Coding for Gradient Color Background for all Platforms

CSS Coding for Gradient Color Background for all Platforms

CSS Coding for Gradient Color Background for all Platforms

(OP)
Can anyone help me with correcting my coding for taking a gradient color background that goes from rust color at the top to black at the bottom in the vertical y direction that repeats in the x direction. I am using a jpg that is a little wider than 1 px that repeats in the x direction. My problem is that I am not getting it to fill in the total height of the page for some pages in various web browsers. What coding correction can be made to make it fill in the total height of the page?

I am using this code in my CSS sheet.

/* Body text and page background */
body {
margin: 0;
padding: 0;
font-family:"Book Antiqua", Times, Serif;
font-size: large;
color:#000000;
background-image: url("pics/black-brown.jpg");
background-repeat: repeat-x;
background-attachment: fixed;
text-align:left;
}

Can the Y direction be set to 100% or something like that?

RE: CSS Coding for Gradient Color Background for all Platforms

This image is only 720 pixels tall so the remainder of the page footer on larger displays (ie: any modern display) should probably be black.

CODE

background-color: black; 

RE: CSS Coding for Gradient Color Background for all Platforms

(OP)
Thanks for that. I didn't think of that solution but it works great.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close