background image

  • pacsunpunk08
  • Graduate
  • Graduate
  • pacsunpunk08
  • Posts: 149
  • Loc: Kenosha, WI

Post 3+ Months Ago

Is there any way u could put a image for the background of a table? Heres any Ex. http://www.residentevilfan.com Thanks
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • anubi
  • Student
  • Student
  • User avatar
  • Posts: 72
  • Loc: Milan - Italy

Post 3+ Months Ago

If you want to add an image as a background inside a table, just place the background="xx" tag inside the <table>.

Adding some CSS you can control various things on your table background like position, repeat, scroll etc etc.

example:


Code: [ Select ]
<html>
<head>
<style type="text/css">
.tablebck {
background-attachment: scroll;
background-image: url(image.gif);
background-repeat: no-repeat;
background-position: left top;
background-color: #006600;
}
-->
</style>
</head>
<body>
<table class="tablebck">
<tr>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
</body>
</html>
  1. <html>
  2. <head>
  3. <style type="text/css">
  4. .tablebck {
  5. background-attachment: scroll;
  6. background-image: url(image.gif);
  7. background-repeat: no-repeat;
  8. background-position: left top;
  9. background-color: #006600;
  10. }
  11. -->
  12. </style>
  13. </head>
  14. <body>
  15. <table class="tablebck">
  16. <tr>
  17. <td> </td>
  18. <td> </td>
  19. <td> </td>
  20. </tr>
  21. </table>
  22. </body>
  23. </html>


Check here for reference:

http://www.w3schools.com/css/css_reference.asp

:wink:
D.
  • gsv2com
  • Professor
  • Professor
  • User avatar
  • Posts: 776
  • Loc: Nippon

Post 3+ Months Ago

Or if you want each table to have a different background, give each table an id and use the following css.

table#id_name {
what he said
}

No matter how many different tables you have, you can set up different backgrounds for each one by changing the "id_name" to the id you gave the table and using the code anubi just gave you.

If you only have one table that you want to have a background, use this format:

table {
css code here
}

Post Information

  • Total Posts in this topic: 3 posts
  • Users browsing this forum: No registered users and 31 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.