Jump to content
Sign in to follow this  
Jorsh

Regular Expressions (Regex)

Recommended Posts

I love the site and refer 5 to 10 people per week to learn about HTML and CSS.One addition that I think would benefit many folks is a regex tutorial. I think with TryIt, W3Schools could be the premier site for learning about regular expressions.Thanks!

Share this post


Link to post
Share on other sites

What do you mean by "regular expressions"? Some kind of info? Anything?

Share this post


Link to post
Share on other sites

Yeah, regular expressions are great for validating form input on web forms.^(\d{5}$|\d{5}-\d{4}$ would only match input that is in valid US zip code format.^[a-zA-Z][\w\.-]*[a-zA-Z0-9]@[a-zA-Z0-9][\w\.-]*[a-zA-Z0-9]\.[a-zA-Z][a-zA-Z]*[a-zA-Z]$ could be used to validate that the user entered in a correctly formated email address.There are many sites on the Internet devoted to regular expressions, I just think it'd be a great addition to this site.

Share this post


Link to post
Share on other sites

Yes this could be useful, it could include:a list of all the charactersa short description on there purposea short example of how the character is usedIn javascript for example:Character = ^Purpose = maches only from the beginning of a lineExample1 = /^c/ matches c in cornExample2 = /^c/ does not match c in acornthen go onto more complicated examples, like validating an email address etc.Thumbs up (only one thing, i don't think it would be considered a high priority)

Share this post


Link to post
Share on other sites

I agree completely. Regex is one thing I've always wanted to learn, as it's come up many times during my work with JavaScript. But like Scott said, I think that Kaijim and his associates are slightly busy right now, so it might take a while for the tutorial to even be started. But still, great idea.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...