how to check the length of a string in jquery
snippet in javascript

how to check the length of a string in jquery

user5299

// How to check the length of input field in jquery
$("selector").val().length
// If '0' is returned, it means input field is empty

string length jquery

user994

var string = "string"
string.length