Google apps
Main menu

Post a Comment On: Blogpad

"Regex"

1 Comment -

1 – 1 of 1
Blogger fc said...

In javascript:

if(number.match(/^\d+$/))
return true;

Another example:

return email.match(/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/);

August 23, 2011 at 1:31 PM

You can use some HTML tags, such as <b>, <i>, <a>

This blog does not allow anonymous comments.

You will be asked to sign in after submitting your comment.
Please prove you're not a robot