DOCTYPE

M

Malcolm Walker

Should my FrontPage 2000 HTML pages start with a DOCTYPE declaration &
if so is the following statement correct?

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
 
M

Malcolm Walker

Kathleen - Thank you for your response.

When I copy & paste your suggested DOCTYPE above <html> FP2000 changes
it to:

<!--StartFragment -->
<pre wrap="">&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01
Transitional//EN"</pre>

However when I edit it back to your suggestion FP seems to accept it.
 
T

Thomas A. Rowe

Paste into Notepad first, then into your page in HTML view.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
M

Malcolm Walker

HTML Tidy has this:

Info: Doctype given is "-//W3C//DTD HTML 4.01 Transitional//EN"
Info: Document content looks like XHTML 1.0 Transitional

Should I change HTML 4.01 to XHTML 1.0?
 
M

Malcolm Walker

I hope I haven't got you wrongly but you seem to imply that I am asking
a stupid question. In a point of fact I asked because I did not know
the answer. You have given me an answer that I take to be correct as I
hold high regard for the responses I read in this newsgroup. Or to put
it in another way the author of HTML Tidy must be misleading me.

Surely the real point of a newsgroup is to disseminate knowledge &
experience amongst those who subscribe to it who are trying to extend
their knowledge of the weird & whacky world of computing? {8;-))

Malcolm
 
M

Murray

Not at all. If you needed to use XHTML you would know that you would have
to change that doctype. If you need to ask whether you need to change it,
then you don't need to use XHTML. See what I mean?

Most people posting here, and indeed most people in general do not *need* to
use XHTML. The only time you would need to use it would be if you are using
XSLT to style XML content, or if you had some specific reason to be using
XHTML (like, for example, you specifically wanted to learn about how to do
well formed HTML).

Pages will do just fine with HTML 4.01 doctypes for the forseeable future.
 
S

Stefan B Rusynko

Actually the doc type can be w/ or w/o the URL depending on what you need
See
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnie60/html/cssenhancements.asp

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


| | > Should my FrontPage 2000 HTML pages start with a DOCTYPE declaration
|
| Yes.
|
| &
| > if so is the following statement correct?
| >
| > <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
|
| No. Try:
|
| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
| "http://www.w3.org/TR/html4/loose.dtd">
|
| For more info: http://www.spiderwebwoman.com/tutorials/doctypesolution.asp
|
| --
| ~ Kathleen Anderson
| Microsoft MVP - FrontPage
| Spider Web Woman Designs
| web: http://www.spiderwebwoman.com/resources/
|
|
|
 
G

Guest

I am really struggling with doctypes. I am trying to validate my code and am
using the W3C validator. No matter what I use I get mutple error messages,
usually starting with the message that my page is not valid 4.01 Transitional
HTML.
Can anyone help, explain, or make a suggestion? I am using Front Page 2002
THANKS.
 
R

Ronx

A doctype is necessary for the validator to decide how to evaluate
your mark up.

The page has two glaring errors, the first of which will fail
validation, the second will prevent the page being displayed correctly
in some browsers:

1) there is no <body> tag. This is essential, and should be
immediately after the </head> tag.

2) The first table has cells with widths of 17%, 92%, 4% that add up
to 113% of the available width. The total should be exactly 100%
 
M

Murray

Len:

From the validator -

Result: Failed validation, 47 errors


You would want to focus on fixing those to get a valid page.

Actually, I have done some of that here -

http://www.murraytestsite.com/safebabyshop.htm

Run the validator on that page (http://validator.w3.org) and you'll see that
there are only two classes of errors (26 in all) -

1. The <meta name="Microsoft Borders" is invalid HTML, but you need it to
work in FP with your shared borders (a single instance of this).
2. Many of the image tags are missing alt attribute values (25 instances of
this). You can fill those in. Ideally, this page should only have 1
error - that mentioned above.

Please look at the code to see where I have fixed things (I left comments
about what I fixed and why).
 
M

Murray

1) there is no said:
after the </head> tag.

Hmm -

<meta name="Microsoft Border" content="b, default">
</head>
<body>
<!--msnavigation-->

Do you not see that, Ron?
2) The first table has cells with widths of 17%, 92%, 4% that add up to
113% of the available width. The total should be exactly 100%

It almost doesn't matter, and for sure, this will not fail validation, as
the validator doesn't check your math! 8)
 
M

Murray

Fail? I don't think so.

Make your page look weird? That would depend on the code on the page. I
would guess that >50% of the pages on the web do not have valid and complete
doctypes, and are therefore rendered in quirks mode. Many large sites rely
on quirks mode to get an accurate rendering of the page - for example they
use table height = 100% to make a page fill the vertical height of the
screen. But such a page must be rendered in quirks mode to do so....
 
R

Ronx

--
Ron Symonds - Microsoft MVP (FrontPage)
Reply only to group - emails will be deleted unread.
FrontPage Support: http://www.frontpagemvps.com/

Murray said:
Hmm -

<meta name="Microsoft Border" content="b, default">
</head>
<body>
<!--msnavigation-->

Do you not see that, Ron?

No - and I searched using Ctrl-F, find "<body" (without quotes), both
up and down.

I saw

<meta name="Microsoft Border" content="b, default">
</head>
<table .....

which is why I searched.
It almost doesn't matter, and for sure, this will not fail
validation, as the validator doesn't check your math! 8)

Yes, it will not affect validation, but it will affect how the page is
displayed in some browsers, such as permanent bottom scrollbar since
the page may never be wide enough to hold the 113% wide table - though
in this case the tables are set to 88% wide, possibly to account for
this (but I am not a mind reader...)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Validating a page 1
When I insert a doctype my home page loses its mind 1
Typing and pasting HTML - Problems 2
DocType 1
Doc Type in FrontPage Webs 1
DOCTYPE problems with scroll-bars 9
DOCTYPE quandry 2
XHTML 2

Top