cara mengatur batas kata dalam jenis teks input
<input type="text"title="likethis()"maxlength="200"placeholder="This will allow only 200 words">
Rich Ray
<input type="text"title="likethis()"maxlength="200"placeholder="This will allow only 200 words">
<script language="javascript" type="text/javascript">
function limitText(limitField, limitNum) {
if (limitField.value.length > limitNum) {
limitField.value = limitField.value.substring(0, limitNum);
}
}
</script>
<input type="text" id="sessionNo" name="sessionNum" onKeyDown="limitText(this,5);"
onKeyUp="limitText(this,5);"" />