Discussion Locked

Using XHTML on an ASP page?

0 helpful
3 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

XHTML Transitional , ASP (not .net) pages

Couple of quick questions:

1. I assume that one can use xhtml in an .asp page?
2. The particular page I am trying to convert has the following code that the w3c html validator doesn't like and would appreciate your suggestions:

<%@ Language=JavaScript %> and similarly ...
<%=GetTransText('IDS_Main_BMOInvestmentCentre')%>

The <% and %> are causing the w3c validator to spew out multiple errors such as "document instance must start with document element" and "character "<" is the first character of a delimiter but occurred as data"

Thanks in advance for your help!

3 replies

by yatin u

Am not sure about XHTML and ASP compatibility with w3c validator but.....
try putting the language="javascript" in double quotes.
i.e javascript in double quotes

by mparter

Are you uploading your ASP file to the validator?

Try entering a URL instead, as the validator will then valid the outputted HTML (or XHTML)rather than the raw ASP page. If you can't directly enter a URL then try running the page locally, viewingthe source, copy it and paste it into a blank html file. Then upload this.

Hope this helps.

by bmacdonald

Don't send the asp file for validation. Send the resulting html page instead. After all, the server processes the asp on its side. It sends the html output to the client. It is that final output that needs to be valid.

This discussion is closed to new replies.