HTML Validation SUDDENLY Problematic

  • Thread starter Thread starter ujjc001
  • Start date Start date
U

ujjc001

2.0 aspx page:

So- today I open a project I worked on probably last wednesday and I
now can't get into design view.

For example, the following page give the following error:

Cannot switch views: Validation (Internet Explorer 6): Element 'style'
cannot be nested within element 'td'.

I've tried changing my validation target type, turning off the show
errors, but nothing helps. Even tried different doc types in the
page. PLEASE help- can anyone else get past validation with this
simple page? I know "it's not suposed to be in a div" but this is
wide spread on my site from an opencube menu (not shown on this page,
but still same dif)... I am really mad because just last time I was
in dotnet it worked fine.
Thoughts?
-----------------------------

<%@ Page Language="vb" AutoEventWireup="false"
CodeBehind="WebForm1.aspx.vb" Inherits="GHC.WebForm1" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div><style></style>

</div>
</form>
</body>
</html>
 
Two things:


Your <head> tag has "runat=server" in it (I'm not sure why you'd want that),
but even if you do, anything that is marked with runat="server" must also
have an id attribute applied to it.

<style> tags are only allowed in the head section of a web page, yours is in
the body.
 
Back
Top