NeDi Community

NeDi General => Other => Topic started by: savanna2009 on January 18, 2010, 08:32:58 PM

Title: how to add more than 1 email account in GUI?
Post by: savanna2009 on January 18, 2010, 08:32:58 PM
Hello community!!!how can I add more than 1 each individual email account in GUI to alert to more than 1 each individual mail(I don't have distribution list at this moment), but each account like : john@hotmail.com;jay@someemail.com...

I like atleast 2 of the email accounts to be alert!!! if they supparate by ,(comma) or ; (semi) etc..

Thanks,
Title: Re: how to add more than 1 email account in GUI?
Post by: harry on January 18, 2010, 11:37:23 PM
Hi ,
Have you tried with Coma(,)...? I think that should work.

Harry.
Title: Re: how to add more than 1 email account in GUI?
Post by: savanna2009 on January 19, 2010, 01:44:43 AM
I have tried with comma or ; semi colon and none of them work...
Title: Re: how to add more than 1 email account in GUI?
Post by: oxo on January 19, 2010, 02:30:47 AM
The code indicates that the nedi.conf has mailfrom and not mailto
It mails to  users who are nedi users in a certain group, 8, who have an email account specified.
Don't know which group 8 maps to, but I guess monitoring

Code: [Select]
# Send Mail
#===================================================================
sub SendMail {

use Net::SMTP;

undef (%main::usr);
&db::ReadUser(8);

print " mailing \"$_[0]\" to:" if $main::opt{v};

my $m = 0;
foreach my $u ( keys %main::usr ){
if($main::usr{$u}{ml}){
print " $u" if $main::opt{v};

# send the message
my $message = Net::SMTP->new($misc::smtpserver) || return "(Can't talk to SMTP server $misc::smtpserver!)";
$message->mail($misc::mailfrom);
$message->to($main::usr{$u}{ml}) || return "failed to send to $main::usr{$u}{ml}!";