D
Deepan Perl XML Parser
my $email = populateEmail("test");
print $email;
open(SENDMAIL, "|/usr/lib/sendmail -oi -t -i") or print "cannot open
SENDMAIL: $!";
print SENDMAIL <<"EOF";
From: <deepan\@juniper.net>
To: ${email}
Subject: [SUSTAINING TICKET] Case
Content-type: text/html
testing
EOF
close(SENDMAIL);
The above code results in "No recipient address found in header"
but when i replace ${email} with direct address say deepan.
17\@gmail.com it works fine.
populateEmail function's code is available below:
sub populateEmail {
if(lc($_[0]) eq "test") {
return ("deepan.17\@gmail.com");
}
}
Can anyone spot the bug?
print $email;
open(SENDMAIL, "|/usr/lib/sendmail -oi -t -i") or print "cannot open
SENDMAIL: $!";
print SENDMAIL <<"EOF";
From: <deepan\@juniper.net>
To: ${email}
Subject: [SUSTAINING TICKET] Case
Content-type: text/html
testing
EOF
close(SENDMAIL);
The above code results in "No recipient address found in header"
but when i replace ${email} with direct address say deepan.
17\@gmail.com it works fine.
populateEmail function's code is available below:
sub populateEmail {
if(lc($_[0]) eq "test") {
return ("deepan.17\@gmail.com");
}
}
Can anyone spot the bug?