Discussions
Categories
Groups
Advertisement
Child Item
Home
Topics
Technology & Internet
Software & Web Development
Design
HTML Table & style sheets
Evil Phil
Hello,
I need to customise the border on my html table. Basically I want to drop the lines at either end of the table (see screen grab). Could somebody tell me how to do that? BTW the screengrab is an asp.net datagrid.
E.P.
Find more posts tagged with
Quick Links
All Categories
Recent Posts
Activity
Unanswered
Groups
Best Of
Advertisement
Advertisement
Comments
Serbian
When you say you want to drop the lines at either end of the table, do you mean the lines between the table cells?
seamus
You can specify borders for TD elements which will acheive what you want, but the CSS is a little messy. From what I see there, you'd need two CSS elements:
TD.firstRowAndLastCol - which has a single border-bottom attribute and is applied to the four cells at the top of the table and to the fourth column in all rows.
TD.normalColumn - which has the border-bottom and border-right attributes set, and is applied to the first three columns on all rows.
If you set the table to have zero cell spacing and just add some padding on the TD element, it should work OK.