# PHP: Fixed Background



## Androo (Sep 5, 2003)

Hey,
I was wondering, what is the php code to make a background stay put while scrolling?
Thanks,
Androo.


----------



## BitWit (Sep 5, 2003)

Well, this isnt exactly php, but here's the css style definition to put into your <BODY> tag:

```
style="background-repeat: no-repeat;"
```
and a good reference for many CSS properties: http://www.htmlhelp.com/reference/css/properties.html


----------



## Androo (Sep 5, 2003)

hehe thanks..
nb3004 suggested something also...

in the <body> tag, make it look like this:
<body background="whatever.jpg" bgproperties="fixed">


----------



## mr. k (Sep 5, 2003)

Yeah but androo you are writing tag-soup!  Why is bloated html bad?  Please see http://webstandards.org/learn/ ...
Thanks for listening to me...


----------



## Captain Code (Sep 24, 2003)

Yes, please follow HTML standards!  Although I don't know if the bgproperties is a valid HTML 4.0 property for the body tag(don't want to look ) if it isn't you should stick to the stylesheet.


----------

