Forum Moderators: open

Message Too Old, No Replies

Doctype, Quirks Mode and tables for layout

         

perryc20

7:53 pm on Mar 18, 2005 (gmt 0)

10+ Year Member




In the past I never used a doctype, on my webpages, however I was told that I should start. Because sometime in the near future browsers will stop displaying websites in quirk mode.

I am starting to use a doctype on all new websites,

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

Since the websites work fine on all major browsers, such as IE, Netscape, Mozilla, Firefox, Opera,etc, then I should be OK (right),

I create websites using tables, and people have told me that this is not the standard anymore, and I should also start using CSS (All of this I understand, however during the time of learning all of these new features in creating websites, I need to stick with what I know.

My question is since the websites look good, with the doctype I am using, shouldn't my websites be OK for the future, with how I created them.

Thanks
Chad

Robin_reala

8:28 pm on Mar 18, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



For the forseeable future I doubt you'll run into problems. Is your code validated? If so then you should be fine.

I wouldn't however carry on coding sites that like, if only for the futureproofing reasons you describe.

esllou

10:03 pm on Mar 18, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I think you can carry on with the tables layout.

tables vs. css for layout is a bit of a different argument to
doctype vs. no doctype.

I am currently redesigning my sites by adding doctypes and using css for all the formatting.

I am still using tables on that main site but instead of a lot of:

<table border="2" bordercolor="red" align="center" width="85%">
<tr align="center" valign="middle" width="50%">

I have reduced it all down to:

<table id="main-info"><tr>

and do all the formatting stuff in the css stylesheet. Produces cleaner, quicker code, have included the doctype so there are vastly fewer cross-browser issues compared to before....and every 20k page I had is now around 16k, 4k of pure html bloat removed.

bt13

4:40 am on Mar 19, 2005 (gmt 0)



If I add the doc type stuff listed above will it mess up what I have working all ready in any way. Just figuring this stuff out slowly and messing something up will just make it that much harder.

Thanx

kaled

10:50 am on Mar 19, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If you omit the url from the doctype (4.01 Trans), IE will render in Quirks Mode but you can still validate your code.
I've been forced to do this to avoid scrollbar issues.

Kaled.