I have a page, where I search by name, cpf or contract, and I'm having difficulty resizing the form when typing.
I think so, when I start typing the characters, you already know that it is by name and it appears the form of size x, if I start typing number, check if it is bigger than 6 numbers is cpf and already inserts the mask when typing and if you start typing numbers and it's less than 11 it's a contract.
I use this data to search a query in SQL Server 2012, depending on the value entered in input
.
<span style="color: #ffffff"><strong>Contrato:</strong></span>
<input name="inpcont" type="text" required id="inpcont" placeholder="Buscar..." onBlur="MM_validateForm('inpcont','','RisNum');return document.MM_returnValue" size="08" maxlength="8"/>
<input id="btnBusca" type="image" src="img/lupasemfundo-22x22.png" vspace="0" hspace="0" onclick="index.php.frmbuscacontrato.submit()"/>