aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Unexpected tag <TABLE> found ,expecting one of <TD> ,<TH> Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Unexpected tag <TABLE> found ,expecting one of <TD> ,<TH>" Watch "Unexpected tag <TABLE> found ,expecting one of <TD> ,<TH>" New topic
Author

Unexpected tag <TABLE> found ,expecting one of <TD> ,<TH>

Satish Nair
Greenhorn

Joined: Apr 04, 2012
Posts: 23
Hello,
I have made a HTML form , but when i run in netbeans there are lot of errors highlighting which is showing errors like Unexpected tag <TABLE> found ,expecteing one of <TD> ,<TH>,
<tr>

<table width="140%" border="0" cellspacing="1" cellpadding="3">
<tr bgcolor="#CCCCFF">




<label for="financial year" class="required"><font size="4"><B>Financial Year</B></font></label>
<select id="financial year" name="financial year" size="1" >
<option value="1">2011-2012</option>
<option value="2">2012-2013</option>
<option value="3">2013-2014</option>
<option value="4">2014-2015</option>
<option value="5">2015-2016</option>
</select>




</tr>
</table>



</tr>

this is part of my code....where <tr>,<table> is displaying the error...kindly help
Nikhil Padharia
Ranch Hand

Joined: Apr 19, 2012
Posts: 37
<tr> is representing a row of the particular table.. Here if you want to have data inside the row you must enclose it with <td> or <th> if it is your header.
You have <table> inside the <tr> but no <td> or <th>, so it complains
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Unexpected tag <TABLE> found ,expecting one of <TD> ,<TH>