Solved

CSS Table Border, Revisited...

Posted on 2004-04-06
2
1,134 Views
Last Modified: 2012-05-05
Please refer to http://www.experts-exchange.com/Web/Q_20944285.html for initial information.

It turns out that I will need to use tables elsewhere on my site.  And those tables should have "no border" like the outer table.  However, the following CSS:
  table table, table table td { border:1px solid #000; border-collapse: collapse;}
affects ALL interior tables.  Is there a way to make a table have a class that also affects the td's inside it?

So that

  <table class=border>
    <tr>
      <td></td><td></td>
    </tr>
  </table>

would have exterior and interior borders and

  <table class=NOborder>
    <tr>
      <td></td><td></td>
    </tr>
  </table>

would not?  I really don't want to have to use "class=" on every td inside the table (there's plenty).
0
Comment
Question by:dgooding
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 14

Accepted Solution

by:
dfu23 earned 75 total points
ID: 10766353
table.NOborder td { border:0; border-collapse: collapse;}
0
 
LVL 2

Author Comment

by:dgooding
ID: 10766451
Thanks dfu23.  Quick easy points.  This is what I've decided to use, with your help...

  table.border { border:1px solid #000; border-collapse: collapse;}
  table.border td { border:1px solid #000; border-collapse: collapse;}
  table.noborder { border:0; border-collapse: collapse;}
  table.noborder td { border:0; border-collapse: collapse;}
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
Does your audience prefer people in photos or no people? How can you best highlight what you’re selling? What are your competitors doing, and what can you do that is different and unique from them?  Continue reading to learn how to make your images …
This video teaches users how to migrate an existing Wordpress website to a new domain.
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question