Hi! There’s an error on saving comments with 1500 char value on my survey.. However, when saving comments with minimum char values such as 100-300 characters, it works so fine.. On my database, the comment was supposed to be stored on comments(column name) with Type of VARCHAR(2000).. And for limiting the value of text area, I have this code..
html:
<textarea name=”limitedtextarea” placeholder=”Type your comments here.” rows=”10″ cols=”50″ onKeyDown=”limitText(this.form.limitedtextarea,this.form.countdown,1500);” onKeyUp=”limitText(this.form.limitedtextarea,this.form.countdown,1500);”></textarea></span><br>
<font size=”1″>(Maximum characters: 1500)<br>
You have <input readonly type=”text” name=”countdown” size=”3″ value=”1500″> characters left.</font>
js:
<script language=”javascript” type=”text/javascript”>
function limitText(limitField, limitCount, limitNum) {
if (limitField.value.length > limitNum) {
limitField.value = limitField.value.substring(0, limitNum);
} else {
limitCount.value = limitNum – limitField.value.length;
}
}
</script>
What do you think is the problem?..