I want to use an input tag to enter text in a cell in a table. I also would like the input box to fill the entire cell. If I use an inline style and set the width to 100% the input box fills the entire cell even when I resize the the page. The problem is when I set the value for the input tag to some large value the input box grows and causes the cell and the table to grow past the width of my page. How do I set the input tag to fill the entire table cell without causing it to grow when a large value is set?
As you can see below everything works great until I enter a large value in the input tag.
Like: value="some very very large text, etc."
Sample Html:
<table border="1" cellspacing="0" width="100%">
<tr>
<td width="50%" align="center">Label 1</td>
<td width="50%" align="center">Label 2</td>
</tr>
<tr>
<td width="50%" align="center">
<input type="text" name="Field1" value="" style="width: 100%;">
</td>
<td width="50%" align="center">
<input type="text" name="Field2" value="" style="width: 100%;">
</td>
</tr>
</table>
Thanks In Advance
As you can see below everything works great until I enter a large value in the input tag.
Like: value="some very very large text, etc."
Sample Html:
<table border="1" cellspacing="0" width="100%">
<tr>
<td width="50%" align="center">Label 1</td>
<td width="50%" align="center">Label 2</td>
</tr>
<tr>
<td width="50%" align="center">
<input type="text" name="Field1" value="" style="width: 100%;">
</td>
<td width="50%" align="center">
<input type="text" name="Field2" value="" style="width: 100%;">
</td>
</tr>
</table>
Thanks In Advance