Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
??? about CSS borders
Old 01-05-2005, 01:03 PM ??? about CSS borders
Novice Talker

Posts: 8
Trades: 0
Is it possible to make the borders inside a table, the lines that seperate rows and columns, look the way a table looks when you use html border attributes but can it be done using CSS. it seems that CSS border styles only affect the outside border and it takes away the borders inside the table and I want the inside border color to match the outside border but the validator tells me that there is no attribute "bordercolor" because "the document type you are using does not support that attribute for this element." I have managed to validate all of the pages at www.bignightout.org except the shows.asp page because of the bordercolor attribute, would changing the DOCTYPE to LOOSE fix it I wonders?
kdg5686 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 01-05-2005, 03:29 PM
faze1's Avatar
Ultra Talker

Posts: 389
Trades: 0
I've noticed this problem aswell and it seesm to get worse from one browser to the next. I don't know a work around for this but what if you were to lose the tables border="?" and create all the borders in css. It wont look like the traditional table boorder but at least everything would be uniformed.

Sorry I couldn't be more useful
__________________
[size=2]
Please login or register to view this content. Registration is FREE
- Webhosting - Focusing on quality service
faze1 is offline
Reply With Quote
View Public Profile Visit faze1's homepage!
 
Old 01-05-2005, 03:39 PM
Extreme Talker

Posts: 160
Trades: 0
Do you mean something like this :

table, td {border:solid red 2px;}

The inner lines should be applied to <td>
The outer lines are applied to <table>
ElectricSheep is offline
Reply With Quote
View Public Profile
 
Old 01-06-2005, 02:22 AM
Novice Talker

Posts: 8
Trades: 0
well now, thanks for your input and that would be the ticket too except I don't want to apply it to all of the tables on this page, just one in particular, I'm a newbee so maybe you could explain how to name a particular table so I could place it with a div? thanks
kdg5686 is offline
Reply With Quote
View Public Profile
 
Old 01-06-2005, 02:36 AM hi
Mooofasa's Avatar
Defies a Status

Posts: 1,611
Name: Michael (mik) Land
Location: England
Trades: 0
Then you must asign an Id to it.

e.g.

Code:
style1#table, td {border: solid red 2px}
Then, when you want it to apply:

e.g.

HTML Code:
<table>
       <tr>
          <td id="style1">
          </td>
       </tr>
</table>
(I think that is right).
__________________

Please login or register to view this content. Registration is FREE
- Tumblog with thoughts, quotes, links, videos, images and my creations.

Please login or register to view this content. Registration is FREE
- The best free web browser.

Please login or register to view this content. Registration is FREE
- Firefox is now Firefail.
Mooofasa is offline
Reply With Quote
View Public Profile Visit Mooofasa's homepage!
 
Old 01-06-2005, 03:37 AM
faze1's Avatar
Ultra Talker

Posts: 389
Trades: 0
Personally I think the css route is a much better choice than border="?".

If you plan on using this for more than one table or cell, you should use a class instead. An ID should only be used once per page.

.anynameyouwant {border:solid red 2px;}

<table class="anynameyouwant">
<tr>
<td>
No border
</td>
</tr>
<tr>
<td class="anynameyouwant">
border
</td>
</tr>
</table>

Since this example only has two cells everything will look like it has a border.

Hope that helps,
__________________
[size=2]
Please login or register to view this content. Registration is FREE
- Webhosting - Focusing on quality service
faze1 is offline
Reply With Quote
View Public Profile Visit faze1's homepage!
 
Old 01-06-2005, 01:41 PM uh huh that's the ticket
Novice Talker

Posts: 8
Trades: 0
hey Mik, I had to do it like this, td#style1 { but it works like a charm, putting id="style1" in every td that I wanted to affect, I think I like it, I like it alot.

and thanks to all of you for your help, I'm glad I joined up with this place !!!
kdg5686 is offline
Reply With Quote
View Public Profile
 
Old 01-06-2005, 01:53 PM
Super Moderator

Posts: 1,576
Location: Kokkola, Finland
Trades: 1
as faze1 said if you use it more than once you need to use a class instead

td.style1 {

then

class="style1"
davemies is online now
Reply With Quote
View Public Profile Visit davemies's homepage!
 
Old 01-06-2005, 02:24 PM ooooopps
Novice Talker

Posts: 8
Trades: 0
hey davemies, I was so danged happy to see it work like I wanted it to without using invalid markup I forgot about faze1 saying only once with the id cause it didn't validate so I did have to change it to a class and now it validates so I'm still happy, thanks alot yous guys cool beaners
kdg5686 is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to ??? about CSS borders
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.29438 seconds with 12 queries