urlencode for Cyrillic


/ Published in: JavaScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function urlencode( str ) {
  2. var ret = str;
  3. ret = ret.toString();
  4. ret = encodeURIComponent(ret);
  5. ret = ret.replace(/%20/g, '+');
  6. return ret;
  7. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.