Solved

Missing DOCTYPE in my web pages

Posted on 2004-04-20
9
214 Views
Last Modified: 2013-12-24
I recently tried to validate one of my web pages and received a "Fatal Error!" response that said there was no Doctype listed on the page.  I use Frontpage 2000 (version 4.0.2) for publishing.  I've investigated Doctypes and see that there are many different kinds out there on the web!  How do I know which one I should put into my pages?  
0
Comment
Question by:vicicicic
  • 4
  • 3
  • 2
9 Comments
 
LVL 29

Accepted Solution

by:
coreybryant earned 200 total points
Comment Utility
What kind of website do you have?  If it is pretty basic - add:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
to the top line of your code.  

You can read more about them here:  http://htmlhelp.com/tools/validator/doctype.html

-Corey
0
 
LVL 31

Expert Comment

by:seanpowell
Comment Utility
Just to add, without confusing the issue:
http://www.positioniseverything.net/articles/doctypes.html

Basically the doctype is a way of telling the broswer how to render your pages - incorporating older deprecated code, or using only the newest standards...

Unfortunately FP2000 doesn't have a method for automatically inserting the code :-(
0
 

Author Comment

by:vicicicic
Comment Utility
I use a lot of nested tables, some java scripts and applets, rollover effects, and a couple of my sites have a form or two.  I use Frontpage themes which I modify.  I do not use Flash files, nothing that would get complicated!  I have read the articles on both of your links, and have a better understanding.  Do you still think the choice of the HTML 4.01 Transitional is right for me?
0
 
LVL 29

Expert Comment

by:coreybryant
Comment Utility
I would say yes.  I have used that before with the nested tables..  Not too many problems..  You will find some issues with nested tables.  The applets - I would say do not use because of the java.

-Corey
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:vicicicic
Comment Utility
Will this DOCTYPE interfere with my java applets, or my java scripts?  Do I really NEED a doctype specified?  My pages have been doing fine and I have not had a DOCTYPE in the code!
0
 
LVL 31

Assisted Solution

by:seanpowell
seanpowell earned 100 total points
Comment Utility
No - you don't "need" a doctype, unless you're concerned with validating your code.

Using a doctype and validating forces you to make sure that your code is written according to the standards, and helps ensure that your pages render "basically" the same cross-browser....
0
 

Author Comment

by:vicicicic
Comment Utility
OK!  Thanks, Sean!  My mind is set to ease, knowing I don't NEED a doctype.  That Fatal Error response from the validator had me worried!  (Takes me back to the old Win 95 days...)  I will try Corey's suggestion of that Transitional HTML code, and  see what happens, I can always take it back out!  I appreciate both of your quick responses.  I will split the points between you.  Thanks.
---Vic
0
 
LVL 31

Expert Comment

by:seanpowell
Comment Utility
Just one last thing if it's okay...

This:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

should ideally be this:

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

The difference is that the first one will leave the browser in quirks mode, the second will generate strict mode - meaning your pages will display more consistently. It's not that one is wrong or right though - either is fine depending on your layout. Just pointing it out :-)
0
 

Author Comment

by:vicicicic
Comment Utility
Thanks, Sean, I'll add it in...   :)
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

In this short web based tutorial, I wanted to show users how they can still use the powers of FrontPage in conjunction with Expression Web 3.  Even though Microsoft eliminated the use of Web components, we can still use them with FrontPage and edit …
Introduction In this tutorial, I'll explain how to create an animated progress meter in a wireframe prototype developed using Axure RP 7.0 - a leading prototyping tool for designing web sites and software. (For more information about Axure and gett…
The purpose of this video is to demonstrate how to connect a WordPress website to Google Analytics. This will be demonstrated using a Windows 8 PC Go to your WordPress login page. This will look like the following: mywebsite.com/wp-login.php :…
The purpose of this video is to demonstrate how to integrate Mailchimp with Facebook. This will be demonstrated using a Windows 8 PC. Mailchimp and Facebook will be used. Log into your Mailchimp account. : Click on your name. Go to Account Setti…

763 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

10 Experts available now in Live!

Get 1:1 Help Now