Posted By

Jamie on 10/20/11


Tagged

url urldecode decode plus


Versions (?)

URl Decode For JavaScript


 / Published in: JavaScript
 

I found some cases where JavaScript won't properly handle the Plus symbol (+)

  1. function urldecode(str) {
  2. return decodeURIComponent((str+'').replace(/\+/g, '%20'));
  3. }

Report this snippet  

You need to login to post a comment.