Snot Posted February 20, 2011 Share Posted February 20, 2011 I have form's made out of tables. Have a look at the search, submit, and contact pages and let me know if this should be done using css instead. www.wararmada.com/tdb Thanks Quote Link to comment https://forums.phpfreaks.com/topic/228264-have-i-used-tables-correctly-or-should-i-be-doing-with-with-css/ Share on other sites More sharing options...
cssfreakie Posted February 20, 2011 Share Posted February 20, 2011 well you are allready using css, but inline style, which makes your tabular design redundant. for example: <td align="right" valign="top">Size</td> Your have quite a bunch of those TD's and they all have the exact same properties (valign and align). better use an external stylesheet that says; table#mytable td.right{ /* so you give your table an id to make sure only the td's inside that will be affected */ valign: top; align: right; } table#mytable td.left{ /* so you give your table an id to make sure only the td's inside that will be affected */ valign: top; align: left; } As you can see i made 2 situations one for left align and one for right align. ones you give the td the right class it behaves as you like. While separating style from the mark-up. Although it might be useful to have a look in something else than tabular design. check out these guys: https://examples.wufoo.com/forms/buy-a-tshirt/ They don't use a table at all. I find that correct since it's not rough data. Quote Link to comment https://forums.phpfreaks.com/topic/228264-have-i-used-tables-correctly-or-should-i-be-doing-with-with-css/#findComment-1177208 Share on other sites More sharing options...
Snot Posted February 21, 2011 Author Share Posted February 21, 2011 Face Palm Well I guess i should go ahead and remake them now while they are not connected to any php. Thanks for the link! That will give me something to go by. Quote Link to comment https://forums.phpfreaks.com/topic/228264-have-i-used-tables-correctly-or-should-i-be-doing-with-with-css/#findComment-1177454 Share on other sites More sharing options...
cssfreakie Posted February 21, 2011 Share Posted February 21, 2011 well if you use tables or Ul's doesn't matter really, but i prefer ul's or divs if it's for design purposes. besides that, you should make those form's on the fly with php Quote Link to comment https://forums.phpfreaks.com/topic/228264-have-i-used-tables-correctly-or-should-i-be-doing-with-with-css/#findComment-1177475 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.