Koozali.org: home of the SME Server
Legacy Forums => General Discussion (Legacy) => Topic started by: Veli-Matti Jokela on April 15, 2003, 06:15:25 PM
-
I know someone had posted this same problem before but there was no solution as far as I know. I installed user panel on my SME 5.6, vacation message works fine when message is sent to username@mycompany.com. But if the message was sent to firstname.lastname@mycompany.com, no vacation message goes back to the sender. Is there anyway to make it work with pseudonyms ?
-
You need to create a ~/.vacation.aliases which contains the pseudonyms you want replies sent to.
firstname.lastname@mycompany.com
firstname_lastname@mycompany.com
etc
More comfortable is to edit /etc/e-smith/web/functions/uservacations
Find the sub
sub performModifyVacation ($)
which is right at the end and paste the following code after this section
open (VACATION, ">/home/e-smith/files/users/$acctName/.vacation.msg")
or die ("Error opening vacation message.\n");
print VACATION "$vacationText\n";
close VACATION;
code to add:
my $alias1= db_get_prop(\%accounts, $acctName, 'FirstName') . "." . db_get_prop(\%accounts, $acctName, 'LastName');
my $alias2= db_get_prop(\%accounts, $acctName, 'FirstName') . "_" . db_get_prop(\%accounts, $acctName, 'LastName');
open (ALIASES, ">/home/e-smith/files/users/$acctName/.vacation.aliases")
or die "Error: Could not open file: /home/e-smith/files/users/$acctName/.vacation.aliases\n";
print ALIASES "$alias1\@$conf{'DomainName'}\n";
print ALIASES "$alias2\@$conf{'DomainName'}\n";
close ALIASES;
-
Thanks ! I did what you told and now it works just as I wanted !!! Great software, amazing support, I'm out of words.
-
Robert,
Should the file that is to be edited (/etc/e-smith/web/functions/uservacations) be templated or is it safe to just edit that file.
Thanks,
Cyrus Bharda