Forum Moderators: not2easy

Message Too Old, No Replies

Easy Question - Background fix?

dont want background to scroll

         

Ecntrc

5:54 am on Jan 21, 2007 (gmt 0)

10+ Year Member



I tried the usual background: fixed, or background-repeat: no repeat, and it dosent work. Do I need to always put it in my html or can it be in css? im not sure where I can put this and I know this is an easy one but im stumped. anyone can help? thanks in advanced and I appreciate it..

Ecntrc

6:03 am on Jan 21, 2007 (gmt 0)

10+ Year Member



heres my code which i forgot to post.. consists of html & css


<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="generator" content="Adobe GoLive">
<title>SERVICES</title>
<link rel="stylesheet" type="text/css"
href="http://www.ecntrcbeauty.org/eb.css" />

<style type="text/css">
<!--

body {
scrollbar-arrow-color:663300;
scrollbar-base-color: ffffff;
scrollbar-darkshadow-color: 663300;
scrollbar-track-color: ffffff;
scrollbar-face-color: FFFFFF;
scrollbar-shadow-color: ffffff;
scrollbar-highlight-color: 663300;
scrollbar-3d-light-color: 663300;
background-image: url(images/index_13.gif);

}
a:link {
color: 663300;
}
a:visited {
color: 663300;
}
a:hover {
color: 663300;
}
a:active {
color: 663300;
}

-->
</style>
</head>

<body STYLE="background-color:transparent">
<table width="549" border="0">
<tr>
<td><img src="webdesignBUTTON.gif" width="260" height="20"></td>
</tr>
<tr>
<td>I offer web design services to new and exhisting clients. Whether its building you a new website or managing your old one. Creating you a unique logo for your company or business cards. I do work from home. I expect or suggest my clients to provide design ideas as well as suggestions. </td>
</tr>
<tr>
<td><div align="left">Programs I work with: </div></td>
</tr>
<tr>
<td>Adobe Photoshop </td>
</tr>
<tr>
<td>Adobe/Macromedia Dreamweaver </td>
</tr>
<tr>
<td>Adobe GoLive </td>
</tr>
<tr>
<td>Ipswitch WS_FTP Program </td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
<tr>
<td>Languages I Use: </td>
</tr>
<tr>
<td>HTML</td>
</tr>
<tr>
<td>CSS</td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
<tr>
<td>Internet Browsers I use: </td>
</tr>
<tr>
<td>Mozilla Firefox</td>
</tr>
<tr>
<td>Internet Explorer </td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
<tr>
<td>Prices:</td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
<tr>
<td>Clients are listed on the <a href="http://www.ecntrcbeauty.org/artwork.html" target="Home"><strong>porfolio</strong></a> page. </td>
</tr>
</table>
<p></p>
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-1133839-1";
urchinTracker();
</script>
</body>

</html>

Robin_reala

9:52 am on Jan 21, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You just need to set background-attachment:fixed on your <body> element. Alternatively you could just use shorthand:

body {
background: url(images/index_13.gif) fixed;
}

By the way, you don’t need to set the background-color to be transparent as that’s the default value.