[bugs] [Bug 1253] Changed - From: address appears as "user%domain@domain" using vpopmail back-end

bugs at bugs.horde.org bugs at bugs.horde.org
Tue May 20 14:09:35 PDT 2003


http://bugs.horde.org/show_bug.cgi?id=1253

*** shadow/1253	Tue May 20 14:03:09 2003
--- shadow/1253.tmp.6401	Tue May 20 18:09:35 2003
***************
*** 29,31 ****
--- 29,48 ----
  ------- Additional Comments From chuck at horde.org  05/20/03 14:03 -------
  You need to either fix your username hook to correct this, or set up a from_hook
  for all users that reformats the address correctly.
+ 
+ ------- Additional Comments From loundry2000 at yahoo.com  05/20/03 18:09 -------
+ I have added the following code to imp/config/conf.php:
+ 
+ $conf['hooks']['from'] = 'extract_email_addr';
+ 
+ if (!function_exists('extract_email_addr')) {
+     function extract_email_addr ($imp) {
+         $user_array = explode ('%', $imp['user']);
+         $domain_array = explode('@', $user_array[1]);
+         return $user_array[0] . "@" . $domain_array[0];
+     }
+ }
+ 
+ The From: address now correctly reports the email address (user at domain).  The
+ HORDE main page incorrectly displays "Welcome, user%domain at domain".  Is there
+ another hook I can write to fix this as well?


More information about the bugs mailing list