Answer Posted / rajender
function isEmail (s) {
if (isEmpty(s))
if (isEmail.arguments.length == 1) return defaultEmptyOK;
else return (isEmail.arguments[1] == true);
if (isWhitespace(s)) return false;
var i = 1;
var sLength = s.length;
while ((i < sLength) && (s.charAt(i) != "@")) {
i++
}
if ((i >= sLength) || (s.charAt(i) != "@")) return false;
else i += 2;
while ((i < sLength) && (s.charAt(i) != ".")) {
i++
}
if ((i >= sLength - 1) || (s.charAt(i) != ".")) return false;
else return true;
}
Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
What companies use javascript?
Can I declare a variable as CONSTANT in JavaScript?
How to loop through array in javascript?
Public Static Void Main(String args[]) { System.out.in("Hai.."); } In the above code why string args[] is required.... If we are not giving command line argument..
how can we retrieve value from one database server and store them another database server using sql server code
List few advantages of using javascript?
What is a framework programming?
Is webassembly faster than javascript?
How to get the type of arguments passed to a function?
What is the use of a weakmap object in javascript?
What is the use of decodeuri() and encodeuri()?
hi i want validations for two drop down lists. when user enter to second list by skipping first list alert box should appear.