"Dennis Allen" <de****@dennisallen.com> wrote:
Have validated every htm file on the
site except:
http://validator.w3.org/check?uri=ht...g.net/mas/COME
T.htm
That's not an "htm file" but a reference to a validator so that the URL
of a page is passed to it. Actually, not even that, since
"Within a query component, the characters ;, /, ?, :, @, &, =, +, ,,
and $ are reserved." (RFC 2396), so the reference is syntactically
malformed.
In the <textarea> of this page I have Javascript code. I can't
figure out how to present this code and still be w3c valid.
Why do you use a form input field when you don't want any user input?
Just put the Javascript code into a separate file and link to it, on a
page that explains what the code does, if you think the code is useful.
If the user's browser starts actually executing Javascript code when he
follows the link, then this will be a useful lesson, and a cheap one as
compared with the possibility of following an innocent-looking link
using a Javascript-enabled browser.
If you insist on embedding Javascript code as visible text onto your
HTML document, then make it really visible, inside <pre> element for
example, instead of forcing the user play with a separately scrollable
area inside a scrollable window.
In any case, any "<" and "&" as data characters in HTML should be
written as "<" and "&". (Using ">" for ">" is never required
by HTML rules, but you might do it for symmetry, or to cope with some
assumed bugs in ancient browsers.) A rhetorical question: are you
qualified to make recommendations to other people about what they
should put into their HTML documents, if you were not able to figure
out this elementary HTML thing on your own?
--
Yucca,
http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring:
http://www.cs.tut.fi/~jkorpela/www.html