Computing.Net > Forums > Web Development > in css...

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

in css...

Reply to Message Icon

Name: kokosovnik
Date: August 14, 2007 at 04:42:02 Pacific
OS: windows xp
CPU/Ram: intel 1gb
Product: pentium
Comment:

what is the difference between background and background-image?? where should i use them?

thanks

you can write me: txakurra@doramail.com



Sponsored Link
Ads by Google

Response Number 1
Name: Laler
Date: August 14, 2007 at 08:16:07 Pacific
Reply:

don't post emails on public pages, spambots are crawling :D

---

background-image is for putting image in background.

I prefer the shorthand. Never used explicit background-image lately.

---

Black colored background:

.className { background: #000000; }

Black color, and an image centered vertically and horizontally. The image isn't tiled (no-repeat) and will scroll with the page:

.className { background: #000000 url('path/file.gif') no-repeat scroll 50% 50%; }


More info: http://www.w3schools.com/css/css_ba...


---
Why can't I change my sig? (this one is manually edited)


0

Response Number 2
Name: mie2com
Date: August 14, 2007 at 12:38:35 Pacific
Reply:

correct me if i'm wrong, but i think "background" would be use to merge all the background attribute at once. example:

background: url("image.jpg") no-repeat fixed #000000

while background-image is just use to insert image in the background.


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Web Development Forum Home


Sponsored links

Ads by Google


Results for: in css...

drop down menu in css www.computing.net/answers/webdevel/drop-down-menu-in-css/2485.html

height of elements in css www.computing.net/answers/webdevel/height-of-elements-in-css/2186.html

website in progress www.computing.net/answers/webdevel/website-in-progress/2382.html