From 6d6b65bf2f27d3e19a4dd1ba9e8023bd77dd002b Mon Sep 17 00:00:00 2001 From: x2004lefloch Date: Sun, 5 Aug 2007 17:06:29 +0000 Subject: [PATCH] Fix FS#703 - Using '+' in email redirections now works as expected. The problem was caused by a double urldecode, done outside of the PHP code, which means the fix is an inelegant hack. git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@1905 839d8a87-29fc-0310-9880-83ba4fa771e5 --- modules/email.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/modules/email.php b/modules/email.php index b735816..1350ec7 100644 --- a/modules/email.php +++ b/modules/email.php @@ -200,6 +200,11 @@ class EmailModule extends PLModule $redirect = new Redirect(S::v('uid')); + // FS#703 : $_GET is urldecoded twice, hence + // + (the data) => %2B (in the url) => + (first decoding) => ' ' (second decoding) + // Since there can be no spaces in emails, we can fix this with : + $email = str_replace(' ', '+', $email); + if ($action == 'remove' && $email) { $retour = $redirect->delete_email($email); $page->assign('retour', $retour); -- 2.1.4