Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
  <meta charset="utf-8">
  <title>JS Bin</title>
<style type="text/css">
textarea {
  display:block;
  margin:1em 0;
}  
</style>  
</head>
<body>
<form>
<label>Maximum 15 characters</label>
<textarea id="textarea" maxlength="15"></textarea>
  <span id="rchars">15</span> Character(s) Remaining
</form>
</body>
</html>
 
var maxLength = 15;
$('textarea').keyup(function() {
  var textlen = maxLength - $(this).val().length;
  $('#rchars').text(textlen);
});
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
w3resourcepro
0viewers