Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS [Solved] CSS Tables

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #161210
    techheadz
    Participant

    I’m still getting used to the switch from HTML to CSS Just wondering what the solution is if you need to create tables using CSS? The best way.

    I think if I am going to adopt CSS fully, I need make sure everything is CSS. What I don’t want to do is place a standard html table inside a DIV.

    I’m already seeing the amount of control you can have over a site design all through one stylesheet, that’s great because everything remains consistent. That is what I am starting to love about it.

    #161211
    Paulie_D
    Member

    There is no ‘ switch from HTML to CSS`…all CSS does is style the HTML you put on the page.

    What I don’t want to do is place a standard html table inside a DIV.

    There are perfectly valid reasons for putting a table inside a div..and equally valid reasons not to. It entirely depends on the circumstances.

    Perhaps you could explain what it is you are trying to do and why.

    #161212
    techheadz
    Participant

    I’m not doing anything in particular, I just wanted to know if it is acceptable to do that, and whether there was an easier way than having to do for example:

    <table width="400" border="1" cellpadding="2" cellspacing="2">
    <tr>
    <td>1</td>
    <td>2</td>
    <td>3</td>
    </tr>
    </table>

    #161217
    Paulie_D
    Member

    Until we know WHY you want to use a table as opposed to some other HTML markup (which, I think was the point of your question)…we can’t answer.

    Using a table to display tabular data is appropriate, even encouraged,…using it for general layout (or even partial layout) is now considered bad practise.

    #161219
    techheadz
    Participant

    You have answered my question, thank you.

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘CSS’ is closed to new topics and replies.