Page is a not externally linkable
- Code, Content, and Presentation
-- HTML
---- Form doesn't validate as XHTML


Gloria - 11:43 am on May 9, 2011 (gmt 0)


Hi,
I wonder if somebody can give me a hand here. I have picked up a free form for choosing different colours, and now I cannot get it to validate as strict xhtml, (it was probably written for html). This is what it looks like:

<form name="choseColor" action="xfer.php" method="post">
<select name="xfer" size="1">
<option selected="selected">Search by colour</option>
<option value="red.html">Red/Pink/Maroon</option>
<option value="blue.html">Blue/Purple</option>
<option value="yellow.html">Yellow</option>
<option value="green.html">Green</option>
<option value="white.html">White</option>
<option value="black.html">Black</option>
<option value="earth.html">Earth/Brown/Beige</option>
</select>
<input type="button" style="height: 22px; width: 40px" onclick="location = ''+document.choseColor.xfer.options[document.choseColor.xfer.selectedIndex].value;"
value="Go!" />
</form>

I have also got a simple back button that also doesn’t validate. That goes like this:

<script type="text/javascript">
function Back() {
window.history.back();
}
</script>
<div id="backButton"><a href="javascript:Back()"><img src="img/button.png" width="80" height="30" alt="Back Button" /></a></div>

I’m new to this so I have no idea how to go about it. I should be very grateful for some help.
Gloria


Thread source:: http://www.webmasterworld.com/html/4309807.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com