Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Web Programming > HTML > HTML Code Clinic
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
HTML Code Clinic Do you have some HTML code you'd like to share and get suggestions from others for tweaking or improving it? This discussion is the place.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the HTML Code Clinic section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 25th, 2006, 10:14 PM
Registered User
Join Date: Nov 2006
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Form doesn't w3c validate, html 4.01

I'm having trouble validating one of the forms on our website. Other forms validate, but this one doesn't want to work. The form is designed to have 3 drop down selectors and a go button. They are meant to display in one row, with about 8 cells (3 drop downs, 1 go button, 3 spacers).

It currently displays correctly, but doesn't validate. The validator complains that:
1. document type does not allow element "FORM" here.
2. document type does not allow element "TR" here.

Whenever I try and rearrange the tags, the display gets horribly messed up. It displays correctly now, but doesn't validate.

The code looks like this:

<tr><td>bunch of stuff</td></tr>

<form action="search.php" method="get" name="SearchPullDown">
<td width="192" height="36" colspan="5"> <img src="images/image1.gif" alt="" ></td>
<td width="158" height="36" colspan="9" class="tableclass1">
<select name="selectname1" class="selectclass" id="id1" style="width:146px; height:20px;">
<option value="Option1" >Option 1</option>
<td width="30" height="36"> <img src="images/abc.gif" alt="" ></td>
<td width="154" height="36" colspan="5" class="tableclass2">
<select name="selectname2" class="selectclass" id="id2" style="width:146px; height:20px;">
<option value="Option2" >Option 2</option>
<td width="23" height="36" colspan="4"> <img src="images/lmn.gif" alt="" ></td>
<td width="157" height="36" colspan="5" class="tableclass3">
<select name="selectname3" class="selectclass" id="id3" style="width:146px; height:20px;">
<option value="Option3">Option3</option>
<td width="61" height="36" colspan="3">
<input type="image" src="images/zyx.gif" alt="Find"></td>


Any help much appreciated. Thanks in advance.

Reply With Quote
  #2 (permalink)  
Old November 26th, 2006, 03:41 AM
Friend of Wrox
Points: 1,315, Level: 14
Points: 1,315, Level: 14 Points: 1,315, Level: 14 Points: 1,315, Level: 14
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Jun 2003
Location: , , .
Posts: 425
Thanks: 0
Thanked 3 Times in 3 Posts

<form action="search.php" method="get" name="SearchPullDown">
You can't have _anything_ between table rows. Not between table cells either. All text and elements other than those the table itself consists of must be contained in table cells.

Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
chapter 3 validate form. lucian BOOK: Professional Ajax ISBN: 978-0-471-77778-6 0 October 16th, 2006 05:17 AM
W3C Validation of FORM steamydave CSS Cascading Style Sheets 2 April 27th, 2005 10:39 AM
Validate form dreamdragon Pro JSP 0 December 11th, 2004 08:11 AM
Validate calculated field in sub form MG76 Access 4 March 18th, 2004 04:26 PM

All times are GMT -4. The time now is 05:06 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.