Monday 20 April 2009

Structure for Regular Expressions in Javascript

Quick note on using Javascript to perform basic RegExp pattern matching - it had been a while since I last tried to do this and I spent some time trying to recall everything. Listed is a (hopefully) functional example demonstrating "trimming" the first part of a URL so only the path is returned - while also serving as a reminder for the syntax:

No comments: