Welcome to HBH! If you have tried to register and didn't get a verification email, please using the following link to resend the verification email.

CSS/Tables


ghost's Avatar
0 0

So I'm looking to make a website and I'm wondering, what do you guys prefer to use: CSS or tables? I can guess that most of you will say CSS but why?

Thanks in advance.


spyware's Avatar
Banned
0 0

CSS: more dynamic

Tables suck.


ghost's Avatar
0 0

tables are good for if you want everything in columns, divs are better for placing everything exactly where you want it. the problem with css/divs is that different browsers and different resolutions can display it differently. it depends on what style of site you want to make as to which to use really.


ghost's Avatar
0 0

Thanks for the input guys

Would like some more opinions though please :D


ghost's Avatar
0 0

CSS has a lot more functionality, and you use it as an external file, so it eases the task of making multiple pages using the same CSS.

If you just wanna chop up something just to make it look presentable, use tables.


ghost's Avatar
0 0

It's really simple:

CSS is for formatting content. Tables are for formatting data.

The end. :)


mido's Avatar
Member
0 0

You have to use tables, to make your contents are equal in length, so that you won't have a text box is not aligned as the one's previous, for instance, regard those as two text boxes, they've to be parallel, for more "good-styling" :


<tr><td> for :
Username |-------|
</td></tr>
<tr><td>
 Password |-------|
</td></tr>

Style your table with CSS. There's no good HTML document, without CSS embedded. Play with margin, and paddings.


ghost's Avatar
0 0

You should replace simple tables with CSS:

http://www.vordweb.co.uk/css/replacing-tables.htm

http://www.alistapart.com/articles/practicalcss/

CSS is good when used in an external file, because it goes in the cache of your web browser. If well done, it will load faster than <table>. You can also use the same CSS on multiple pages, and since it is already in the cache, users will not need to redownload it.

<table> is useful when you have a lot of data that need to be aligned. It can become tricky to do so with CSS, and especially when the data is generated by a server side script.