#124 Bugfix to send mail to local users

open
nobody
None
5
2007-06-19
2007-06-19
No

Since I disabled myself as developer for this project, I post this here.
Users should be able to "mail" other local users. A small bug prevented this. Here's the fix:

in the file modules/webmail2/inc/webmail2_func.inc.php, function getmailadr (around line 383), change the following line:

$str2 = trim($arr[0]->mailbox."@".$arr[0]->host);

to:

if ($arr[0]->host) {
$str2 = trim($arr[0]->mailbox."@".$arr[0]->host);
} else {
$str2 = trim($arr[0]->mailbox);

Franky

Discussion

  • dtandukar
    dtandukar
    2007-09-05

    Logged In: YES
    user_id=1088865
    Originator: NO

    this did not work... when i changed the line, the webmail gives me the blank page

    DT

     
  • Logged In: YES
    user_id=109671
    Originator: YES

    just forgot to close the brackets, that's all ... add an extra "}" at the end
    The complete code:
    if ($arr[0]->host) {
    $str2 = trim($arr[0]->mailbox."@".$arr[0]->host);
    } else {
    $str2 = trim($arr[0]->mailbox);
    }

    Franky