473,385 Members | 1,582 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Why is this page invalid?

Why is this page invalid?

Pasted into http://validator.w3.org/ I'm told that the page is
invalid. Why? It flags problems with the <bodyand </htmltags but
I can't see why. Is the W3C validator broke is or it my page? If it's
my page then what's wrong with it?
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://
www.w3.org/TR/html4/frameset.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>my page - Login</title>
<link href="images/login.css" rel="stylesheet" type="text/css">
<script src="javascript/browser.js" type="text/javascript"></script>
</head>

<body>

<!--start header - contains my page logo-->
<div id="header">
<span>A Logo</span><span id="nav">Home | <a
href="contact.aspx">Contact</a></span>
</div>
<!--end header-->

<!--start login - contains login box and photo-->
<div id="login">

<form method="post" id="frmMain" action="Default.aspx">
<div id="divMain">
<p class="subLogin">Subscriber Login</p>
<p><label for="txtUserName">User Name</label><br>
<input class="mwInput" size="16" name="txtUserName" id="txtUserName"
type="text" title="Please enter text (do not cut and paste)"><br></p>

<p><label for="txtAccessCode">Access Code</label><br>
<input class="mwInput" size="16" name="txtAccessCode"
id="txtAccessCode"
onkeypress="if(event.keyCode==13)validateLoginDeta ils();"
type="password" title="Please enter User and Access codes using
correct letter case."></p>

<div id="loginButton"><a id="loginButtonA"
href="javascript:validateLoginDetails();"LOGIN </a></div>

<p id="ForgotPWD"><a href="contact.aspx?
Action=ForgotPassword">Forgot Password</a></p>
</div>
</form>

<img id="mainphoto" src="images/hd_photo.jpg" width="520" height="260"
alt="two businessmen at a meeting"></div>
<!--end login-->

<!--start tickertape-->
<div id="tickertape">
<iframe marginwidth="0" src="tickertape.aspx" marginheight="0"
frameborder="0" height="17" scrolling="no" width="750"></iframe>
</div>
<!--end tickertape-->

<!--start main div - contains left and right columns and footer and
centres content on the screen-->
<div id="main">

<!--start col1 - this is the lefthand column (services)-->
<div id="col1">
<h3>Subscriptions</h3>
<h3>Services</h3>
<h4>Newswire &amp; Database</h4>
<h4>Watch</h4>
<p>&nbsp;</p>
<h4Analysis</h4>
</div>
<!--end col1 column-->

<!--start col2 - this is the righthand column (welcome, etc.).
Placed first in html code for SEO.
CSS 'float' property is used to switch column position for layout
purposes-->
<div id="col2">

<div class="col2cont1">
<h3>
Some content</h3>
</div>

<div class="col2cont1">
<h3>
Some more content</h3>
</div>
<div class="col2cont2">&nbsp;</div>
</div>

<!--end col2 column-->

<!--start footer-->
<div id="footer">
<p>A footer<a href="http://www.mypage.com"></a></p>
</div>
<!--end footer-->

</div>
<!--end main div-->

</body>
</html>

Jun 25 '07 #1
9 2756
mark4asp wrote:
Why is this page invalid?
<html snipped>

You are using a frameset doctype on a page that is not a frameset.

Change the doctype to

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

Then it will validate.
Jun 25 '07 #2
Beauregard T. Shagnasty wrote:
..and whether the page validates with either, will depend solely on
the lack of errors. <g>
I tried validating it as HTML 4.01 strict, and there were errors. I
tried as HTML 4.01 transitional, and it validated.

Using an HTML 4.01 strict doctype and correcting the errors would be
preferred, but using an HTML 4.01 transitional doctype will work for the
page in question.
Jun 25 '07 #3
in message <11*********************@k79g2000hse.googlegroups. com>, mark4asp
('m*******@gmail.com') wrote:
Why is this page invalid?

Pasted into http://validator.w3.org/ I'm told that the page is
invalid. Why? It flags problems with the <bodyand </htmltags but
I can't see why. Is the W3C validator broke is or it my page?
It's your page.
If it's
my page then what's wrong with it?
You've specified the FRAMESET DTD. The FRAMESET DTD does not allow BODY.
You want the STRICT DTD.

--
si***@jasmine.org.uk (Simon Brooke) http://www.jasmine.org.uk/~simon/
;; "If I were a Microsoft Public Relations person, I would probably
;; be sobbing on a desk right now" -- Rob Miller, editor, /.

Jun 25 '07 #4
Dan

mark4asp wrote:
Is the W3C validator broke is or it my page?
Out of curiosity, out of all the people who have asked this question
on this newsgroup over the years, have *any* of their situations
*ever* turned out to be a genuine case of the W3C validator being
broken?

--
Dan

Jun 25 '07 #5
mark4asp wrote:
Which is a real shame because iframes are so very useful for AJAX but
I should try replacing it with an object.
Huh?

I don't have much experience with AJAX, but it seems to me that using
AJAX should allow you to do the same things without iframes. AJAX should
allow you to use a div in place of the iframe.
Jun 26 '07 #6
On 26 Jun, 16:04, Scott Bryce <sbr...@scottbryce.comwrote:
I don't have much experience with AJAX, but it seems to me that using
AJAX should allow you to do the same things without iframes. AJAX should
allow you to use a div in place of the iframe.
AJAX only works if the content to be loaded is well-formed XML (which
could be XHTML, so long as it _is_ well-formed).

If you're trying to load non-XML HTML, or "typical" XHTML that isn't
well-formed XML, then you have to stick with loading it into an
<iframe>

Jun 26 '07 #7
Andy Dingley wrote:
If you're trying to load non-XML HTML, or "typical" XHTML that isn't
well-formed XML, then you have to stick with loading it into an
<iframe>
I have only done one AJAX project, and that wasn't my experience. I used
AJAX specifically to avoid managing iframes, and I loaded HTML to avoid
having to parse XML into HTML. By sending data to the page as HTML, I
was able to write it directly into divs.

So maybe what I was doing was AJAH?
Jun 26 '07 #8
On Tue, 26 Jun 2007 11:57:24 -0600, Scott Bryce <sb****@scottbryce.com>
wrote:
>AJAX specifically to avoid managing iframes, and I loaded HTML to avoid
having to parse XML into HTML. By sending data to the page as HTML, I
was able to write it directly into divs.
So how did you load it?
Jun 26 '07 #9
Andy Dingley wrote:
On Tue, 26 Jun 2007 11:57:24 -0600, Scott Bryce <sb****@scottbryce.com>
wrote:

>>AJAX specifically to avoid managing iframes, and I loaded HTML to avoid
having to parse XML into HTML. By sending data to the page as HTML, I
was able to write it directly into divs.


So how did you load it?
Well that is an interesting question, and not one I'm sure I can answer.
I used Perl's CGI::Ajax module to do a lot of the heavy work for me. The
CGI::Ajax module embeds the JavaScript that communicates with the server
into the web page. What that means is that it works, and I couldn't tell
you exactly how.

All I know is that I did what the docs for the CGI::Ajax module told me
to do. My perl script returns HTML, it is passed to a function where I
set the innerHTML of the div in question to the HTML that was returned,
and it works.

As I was reading up on AJAX, I didn't see anything that REQUIRED XML to
be sent to the web page. You can send any text string that your
JavaScript can parse into usable HTML.

It has been a while since I wrote it, and I may be remembering things
all wrong. As I mentioned, it is the only AJAX I have written. I don't
know much about it. What I do know is that I didn't use XML.
Jun 26 '07 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

37
by: ajay | last post by:
How to make a web page getting refreshed after a given time interval automatically. HTML Code plz. Tx Ajay
3
by: Gvnn | last post by:
Hi, I've a little problem, i've an asp.net page, with a runat server form, like this: <%@ Page Language="vb" AutoEventWireup="false" Codebehind="index.aspx.vb" Inherits="indexGstPro"%> <HTML>...
2
by: .NET Developer | last post by:
On our external customer facing website recently we included a global error catching routine and forward the error message to our support team via email. We notice many emails with the following...
2
by: Brad | last post by:
I have an intranet app that has just started sporadically getting the following error "The viewstate is invalid for this page and might be corrupted." By sproadic I mean 3-4 times during the past...
7
by: Jason | last post by:
Can anybody help on the following error : The viewstate is invalid for this page and might be corrupted. Description: An unhandled exception occurred during the execution of the current web...
6
by: scottyman | last post by:
I can't make this script work properly. I've gone as far as I can with it and the rest is out of my ability. I can do some html editing but I'm lost in the Java world. The script at the bottom of...
5
by: acord | last post by:
Hi, I m getting annoying display problem when placing javascript tags in a html page. Should the javasscript tags placed at the beginning of a html page before anything start? or placed between...
3
by: Nathan Sokalski | last post by:
I am recieving the following error on the second postback of a page I have written: The state information is invalid for this page and might be corrupted Stack Trace: ...
0
by: mwmorrison93 | last post by:
Hello, I'm at my wit's end regarding the "The state information is invalid for this page and might be corrupted" error and I'm hoping someone can provide some assistance. I working with C#/ASP.NET...
7
by: tshad | last post by:
I have a page that is showing as: Page.IsValid = False on postback when my submit button is pressed but none of my Validators have fired so there is no error message. How do I find out what...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.