Fix FS#703 - Using '+' in email redirections now works as expected. The problem was...
authorx2004lefloch <x2004lefloch@839d8a87-29fc-0310-9880-83ba4fa771e5>
Sun, 5 Aug 2007 17:06:29 +0000 (17:06 +0000)
committerx2004lefloch <x2004lefloch@839d8a87-29fc-0310-9880-83ba4fa771e5>
Sun, 5 Aug 2007 17:06:29 +0000 (17:06 +0000)
git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@1905 839d8a87-29fc-0310-9880-83ba4fa771e5

modules/email.php

index b735816..1350ec7 100644 (file)
@@ -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);