954,604 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

css help

guys i need some help on inserting images in css,particularly background images.

az_master
Newbie Poster
15 posts since Nov 2007
Reputation Points: 10
Solved Threads: 0
 

Hi,
what help do you need? What are you are trying to achieve?

How do you want your background image to appear?

For instance, is the image a graphic that will repeat horizontally or vertically or is it a photo or something similar that will act as a watermark?

PCResolver
Light Poster
25 posts since Mar 2008
Reputation Points: 10
Solved Threads: 3
 

Please, more information!

Still, for guessing...

Initial Call...

{
background-image: url(images/mypicture.jpg);
}


Is the initial CSS to use.
Please note that the URL can be handled in 2 different ways.
1)Explicit - you use the FULL path to the file... such as from the root directory... images/products/bigimages/happyimage.jpg
2)Relative - the image is in a folder/directory or sub-folder/directory of the CSS file if it is external.

Thus, if you have inline or embedded CSS, then the URL should be Explicit.
If external CSS files are being used, then you can use either Explicit or Relative.For positioning of the image...

{
background-image: url(path_to_image/file_name.ext); 
background-position: H V;
}


The position values can be;
1) Exact - measurements in PX etc.
2) Relative - em/% etc.
3) Text - left/right/center/top/bottom etc.tiling of the image...

{
background-repeat: repeat_value;
}


The Repeat Value can be;
1) repeat-x - for Horizontal (L to R) tiling/repeating.
2) repeat-y - for Vertical (T to B) tiling/repeating.
3) no-repeat - for no tiling/repeating.

You can also try "fixing" the position... though that can get a little confusing.


Does any of that help?

autocrat
Posting Pro in Training
431 posts since Feb 2005
Reputation Points: 63
Solved Threads: 12
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You