Skip to content
Snippets Groups Projects
Commit f68f5254 authored by Dries Buytaert's avatar Dries Buytaert
Browse files

- Patch #191116 by david: make drupal_urlencode() rfc 1738 compliant to make...

- Patch #191116 by david: make drupal_urlencode() rfc 1738 compliant to make it work correctly with spaces.
parent 75ea35a6
Branches
Tags
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
...@@ -2272,10 +2272,10 @@ function drupal_urlencode($text) { ...@@ -2272,10 +2272,10 @@ function drupal_urlencode($text) {
if (variable_get('clean_url', '0')) { if (variable_get('clean_url', '0')) {
return str_replace(array('%2F', '%26', '%23', '//'), return str_replace(array('%2F', '%26', '%23', '//'),
array('/', '%2526', '%2523', '/%252F'), array('/', '%2526', '%2523', '/%252F'),
urlencode($text)); rawurlencode($text));
} }
else { else {
return str_replace('%2F', '/', urlencode($text)); return str_replace('%2F', '/', rawurlencode($text));
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment