Skip to main content
Ben Nadel
On User Experience (UX) Design, JavaScript, ColdFusion, Node.js, Life, and Love.


Member since Feb 28, 2009

Recent Blog Comments By Magmatrix

  • Ask Ben: Javascript String Replace Method

    Posted on Feb 28, 2009 at 11:27 AM

    Please note that you have a race condition if you do something like: s="my string with % percent in it"; s.replaceAll("%","%20"); // URL encoding example Any "%" will be replaced with "%20", which will then be replaced with "%%20", then "%%%20" and so, using 100% cpu, eating memory until your brow... read more »