I'm trying to use JQuery maxlength()
in a <textarea>
but I'm getting an error$(…).maxlength is not a function
C#
<form id="form1" runat="server">
<asp:TextBox ID="TextBox1" runat="server" TextMode="MultiLine" Width="300" Height="100"></asp:TextBox>
<br />
<br />
<div id="counter">
</div>
</form>
Jquery
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script type="text/javascript">
$(function () {
//Normal Configuration
$("[id*=TextBox1]").MaxLength({ MaxLength: 10 });
});
</script>