diff options
author | Gábor Hojtsy <gabor@hojtsy.hu> | 2007-07-13 20:07:15 +0000 |
---|---|---|
committer | Gábor Hojtsy <gabor@hojtsy.hu> | 2007-07-13 20:07:15 +0000 |
commit | 3cccee7f4a3a02277287adee074ba86b71af69d8 (patch) | |
tree | ba0a7e648847576fdfcf28762e7747bd277fc334 /misc | |
parent | 51b789c0d3091252d3db6bf25e75428fccb3bb98 (diff) | |
download | brdo-3cccee7f4a3a02277287adee074ba86b71af69d8.tar.gz brdo-3cccee7f4a3a02277287adee074ba86b71af69d8.tar.bz2 |
#158687 by drumm: fix URI encoding of some special chars
Diffstat (limited to 'misc')
-rw-r--r-- | misc/drupal.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/misc/drupal.js b/misc/drupal.js index 0c155f7d6..c2e862435 100644 --- a/misc/drupal.js +++ b/misc/drupal.js @@ -369,8 +369,8 @@ Drupal.unfreezeHeight = function () { */ Drupal.encodeURIComponent = function (item, uri) { uri = uri || location.href; - item = encodeURIComponent(item).replace('%2F', '/'); - return uri.indexOf('?q=') ? item : item.replace('%26', '%2526').replace('%23', '%2523'); + item = encodeURIComponent(item).replace(/%2F/g, '/'); + return (uri.indexOf('?q=') != -1) ? item : item.replace(/%26/g, '%2526').replace(/%23/g, '%2523').replace(/\/\//g, '/%252F'); }; /** |