CSS with Tables - Any Browser Issues?

Posted on 2006-04-28
Last Modified: 2008-03-10
Hello CSS Gurus,

I develop with and use as muched "stripped out" html as I possibly can get away with.  I really like CSS, even though I mostly give the job to someone else on my team.  But here is my question... how much can I get away with on Table properties with CSS without running into any browser related issues?

For example... any non-IE browser, Mozilla, FireFox and such... how far can I go here with CSS table properties?


All detailed advice especially appreciated.
Question by:born4code
    LVL 8

    Accepted Solution

    cellspacing = css margin, common support
    cellpadding = css padding, common support
    width = css padding
    align = css text-align, common support
    border = css border properties, common support
    height = not in css, not part of html standard either
    colspan = structure, not style
    rowspan = structure not style
    bgcolor= more flexibility in css, common support
    src= more flexibility in css, common support

    Basically you're better off using CSS in all instances. Basically you'll have *more* control on tabular data display with CSS.

    If you want exmaples on syntrax for any of these, shout out.
    LVL 2

    Author Comment

    Well, it looks like everything there is covered, except rowspan and colspan which I can keep in the html.  Yes, if you have any samples or something like that to get me started it would be a huge help.
    LVL 30

    Assisted Solution

    Somme corrections:

    cellspacing = css border-spacing (not css margin!!!), and is not supported by IE6.

    width = css width , common support
    height = css height, common support

    So, cellspacing is the only attribute that you'll need to specify as HTML attribute...
    If you want no cellspacing at all, then you can use css "border-collapse: collapse;" which has the same effect as setting cellspacing=0.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer …
    So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
    In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
    In this tutorial viewers will learn how to style rounded corners for elements in CSS using the border-radius property Begin with a normal styled element such as a div: To style all four corners of the div to be the same degree of roundness, use the …

    794 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

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now