|
|
|
||||
|
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
|
|||||||
| New Webmasters ask "How-To" questions here. This is where other fucking Webmasters help. |
|
|
Thread Tools |
|
|
#1 |
|
Confirmed User
Join Date: May 2004
Posts: 123
|
css question
hiya ppl... i am using an image as a background in a table. but i want that image to not repeat itself when the table is stretched larger then its height... i was told i could fix this with css and i have looked around and read about it... but i cant find any straight forward answer for putting it into a table...
help please!
__________________
Great MONEY making opportunity - Casino Cash |
|
|
|
|
|
#2 |
|
Confirmed User
Join Date: Feb 2004
Location: Ohio, US
Posts: 662
|
in the table tag, or wherever you have it, in the 'background' attribute you need to have no-repeat, so if your using a style attribute (inline css) you'd use style="background: no-repeat;" or just add no-repeat to your existing bcakground attribute if you have one already eg: 'background: url('/images/bg.gif');' becomes 'background: url('/images/bg.gif') no-repeat;'
hope that clears it up for you. |
|
|
|
|
|
#3 |
|
Confirmed User
Join Date: May 2004
Posts: 123
|
hey cheers,
i changed this line to <td width="680" height="377" valign="top" background="images/bgbeta.jpg" style="background: no-repeat;" > but that made the bg dissappear?? could that be because i already have css style for my scroll bars defined at the top of my html? hence i have to then define everything up there now? im a bit new to all the css stuff... i also tried defining the background properties up the top, but im not sure that i was calling it correctly back down in the html where my table was... help please!
__________________
Great MONEY making opportunity - Casino Cash |
|
|
|
|
|
#4 |
|
Confirmed User
Join Date: Oct 2004
Location: Sin City Baby...
Posts: 1,725
|
What size is the image and what size is the table??
__________________
Shoes and Boot |
|
|
|
|
|
#5 |
|
Registered User
Join Date: Aug 2004
Posts: 8
|
See below for what you're trying to do.
The path to the image can be relative or absolute if you're deploying in a war file or something to that effect. note the embedded DIV that inherits from the td class. Code:
<html>
<style>
td.logo div {background-image: url(corner-black.gif); }
</style>
<body>
<!-- the above style should read td dot logo div open curly then the rest of the line - it is getting munged when i post -->
<table>
<tr>
<td class="logo"><div>Row 1, Cell 1</div></td><td>Row 1, Cell 2</td>
</tr>
<tr>
<td>Row 2, Cell 1</td><td class="logo"><div>Row 2, Cell 2</div></td>
</tr>
</table>
</body>
</html>
|
|
|
|
|
|
#6 |
|
Confirmed User
Join Date: May 2004
Posts: 123
|
cheers heaps for you help here dexterlab!
i entered this into my css style section at the top: td.bglogo { background: url('images/bgbeta.jpg') no-repeat;} and then i just called the bglogo class like so: <td class=bglogo width= etc. etc.> as its just one table that i want it in... so does that seem correct? it seems to be working... i didnt include the div though... did i need to ? but i cant see it in dreamweaver, only when i actually preview it in a browser... ps. it seems that haha123; equals the left curly bracket...
__________________
Great MONEY making opportunity - Casino Cash |
|
|
|