...

View Full Version : Jump Menu Works but Does not Validate



mikacruz
10-17-2008, 01:12 PM
Hello fellows,
I have checked a page that contains several jump menus, with validator.w3.org,
The jump menus work fine but they show lots of errors for the validator.
Here is the page in question (http://www.sacred-egypt.com/testkizza.html)

Line 44, Column 24: document type does not allow element "select" here; missing one of "p", "h1", "h2", "h3", "h4", "h5", "h6", "div", "pre", "address", "fieldset", "ins", "del" start-tag.

<select name="jump_menu">

Line 50, Column 109: document type does not allow element "input" here; missing one of "p", "h1", "h2", "h3", "h4", "h5", "h6", "div", "pre", "address", "fieldset", "ins", "del" start-tag.

…ura.com/blank.gif" alt="jump button"/>

If anyone knows whats wrong, please let me know :)
Thanks a lot

Aradon
10-17-2008, 05:59 PM
Java != javascript or html validation

itsallkizza
10-17-2008, 07:56 PM
This isn't a javascript issue, it's a doctype issue. Iirc a change to transitional will fix those errors.

Or you can place all your selects in empty divs.

The principle behind the exceptions: every inline element (ie all actual content) needs to be inside a block element for strict DOM.

All the tags w3 validator is listing are block elements you can use to wrap your selects.

Also, make sure there is a space between your last attribute and the "/>" - this is for legacy browsers.

mikacruz
10-20-2008, 10:04 PM
Thank you,
Sorry for putting thread in wrong topic ;-)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum