Hello
I validated the code below in http://validator.w3.org/
It says
end tag for "select" which is not finished
</select>✉
Most likely, you nested tags and closed them in the wrong order. For example <p><em>...</p> is not acceptable, as <em> must be closed before <p>. Acceptable nesting is: <p><em>...</em></p>
Another possibility is that you used an element which requires a child element that you did not include. Hence the parent element is "not finished", not complete. For instance, in HTML the <head> element must contain a <title> child element, lists require appropriate list items (<ul> and <ol> require <li>; <dl> requires <dt> and <dd>), and so on.
I have no idea on what is wrong coz' I have used similar codes in other pages with no prob. The only difference is here i'm using for loop and in the other pages i'm using while loop. But I think that shouldn't matter.
Can anyone please please help me? 🙁 I've spent hours on this.
The code in red is where the error occurs.
<form name="cr_card_disp2_frm" action="confirm.php" method="post">
<div class='form_label1' style='left:7%;'>Payment</div>
<div class='form_element' style='right:40%; vertical-align:middle;'>
Expiration Date:
<select name="exp_mth">
<?php
for ($mth=1; $mth<=12; $mth++)
{if ($mth < 10)
echo "<option>"."0".$mth."</option>";
else
echo "<option>".$mth."</option>";
}
?>
[COLOR="Red"]</select>[/COLOR]
<input type="submit" value="Continue Checkout" style="position:absolute;top:0;right:-15%;" />
</div>
</form>
thanks a lot