|
|
| Author |
Message |
sfwweb
Joined: 09 Mar 2004 Posts: 66
|
Posted: Fri Mar 12, 2004 12:56 pm Post subject: |
|
|
| Style sheets are pretty useful for large-scale projects. Do you know how to include a gradient image as a background for a table using style sheets? |
|
| Back to top |
|
 |
DutchMan
Joined: 07 Mar 2004 Posts: 66
|
Posted: Fri Mar 12, 2004 1:10 pm Post subject: |
|
|
An example:
| Code: | table {
background-attachment: fixed;
background-image: url(images/top.gif);
background-repeat: repeat;
background-position: left top;
} |
- DutchMan - |
|
| Back to top |
|
 |
espmartin

Joined: 04 Mar 2004 Posts: 177
|
Posted: Fri Mar 12, 2004 1:14 pm Post subject: |
|
|
You want to id the table, because if you have mulitple tables, you may not want all of them to have the background.
CSS:
| Code: | <style type="text/css">
<![CDATA[
#test-table { background: transparent url(images/rsaclabel-172x30.gif) repeat left top;
]]>
</style> |
HTML:
| Code: | <table id="test-table">
<tr>
<td>test</td>
</tr>
</table> |
_________________ Best Regards,
Martin E.
San Francisco Bay Area & Central Valley
(Web) Web Design Standards - XHTML content, CSS presentation & Accessibility |
|
| Back to top |
|
 |
sfwweb
Joined: 09 Mar 2004 Posts: 66
|
Posted: Fri Mar 12, 2004 1:23 pm Post subject: |
|
|
THANKS! I've been looking for it all over on the internet! By the way, what size is the gradient supposed to be? Can it be anysize, let's say, 13 pixels by 100 pixels?  |
|
| Back to top |
|
 |
|