By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,838 Members | 2,222 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,838 IT Pros & Developers. It's quick & easy.

Im in school and need help with Validation

nd21402
P: 1
I created a page and I have tried to validate numerous times with no success. My page is still showing 3 errors... I have been working on these for hours and I can really use some help..

The codes are as follows:

Below are the results of checking this document for XML well-formedness and validity.

Error Line 7, column 9: an attribute value specification must be an attribute value literal unless SHORTTAG YES is specified .
<p class=MsoNormal>

Error Line 8, column 19: document type does not allow element "div" here; missing one of "object", "applet", "map", "iframe", "button", "ins", "del" start-tag .
<div align="center">
The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element.

One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").



Error Line 17, column 6: end tag for "p" omitted, but OMITTAG NO was specified .
</body>
You may have neglected to close an element, or perhaps you meant to "self-close" an element, that is, ending it with "/>" instead of ">".



Info Line 7, column 0: start tag was here .
<p class=MsoNormal>


Source Listing
Below is the source input I used for this validation:
[html]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>WEB110 SITE DEVELOPMENT WORK</title>
</head>
<body>
<p class=MsoNormal>
<div align="center">
<h3>Hi D.I... I'm still alive and trying very hard to keep up with the class :)</h3>
<p><font face="arial" size="4" color="#0000bb">Check out the following links</font></p>
<p></p>
<p><font face="arial" size="4" color="#0000bb"><a href="http://lamp.cpcc.edu/~ndrinka0/pages/play.htm">Play Page</a></font></p>
<p><font face="arial" size="4" color="#0000bb"><a href="http://lamp.cpcc.edu/~ndrinka0/pages/Personal.htm">Personal Page</a></font></p>
<p><font face="arial" size="4" color="#0000bb"><a href="http://lamp.cpcc.edu/~ndrinka0/pages/Project.htm">Project Page</a></font></p>
<p><font face="arial" size="4" color="#0000bb"><a href="http://lamp.cpcc.edu/~ndrinka0/pages/web110.htm">Web110</a></font></p>
</div>
</body>
</html>[/html]
Mar 13 '07 #1
Share this Question
Share on Google+
1 Reply


drhowarddrfine
Expert 5K+
P: 7,435
class names must be enclosed in quotes.
You don't have a closing </p> for your first one. Also, that <p> encloses a <div>. <p> can only contain inline elements while <div> is a block level element.
In addition, the <font> tag has been deprecated. You should be using css.

A further note, the msonormal class is telling me you are trying to use Word as a web page creator. Word creates horrendous, invalid code. Don't use it.
Mar 13 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.