Gossamer Forum
Home : Products : Links 2.0 : Installation -- Unix :

&html_validate_email (%{$links{$id}})

Quote Reply
&html_validate_email (%{$links{$id}})
It always worked well, but now the validation function wont work! The problem is the mail-function. If I put it off, it works - otherwise I get a no data error of netscape.

If I comment &html_validate_email (%{$links{$id}}) out everything works well, so it is the mailfunction. ONLY mailer.pm works correct, because other mails keep on coming!





Code:
if ($db_email_add) {
ID: foreach $id (keys %validate_list) {
if ($validate_list{$id}) { next ID; }
elsif (${$links{$id}}{'Contact Email'} =~ /(@.*@)|(\.\.)|(@\.)|(\.@)|(^\.)/ | |
${$links{$id}}{'Contact Email'} !~ /^.+\@(\[?)[a-zA-Z0-9\-\.]+\.([a-zA-Z]{2,3}|[0-9]{1,3})(\]?)$/) {
$errstr .= ($errstr, "<li>Email Error: <strong>$id</strong>. Record validated, but couldn't send auto email. Reason: Bad Email addres: '${$links{$id}}{'Contact Email'}'.");
}
else { &html_validate_email (%{$links{$id}}); }
}
}
Quote Reply
Re: &html_validate_email (%{$links{$id}}) In reply to
I see you're trying to validate a file.

Is the file being validated but the email is not being send? Then there's s problem with Mailer.pm

How it exactly works I don't know, that's why i stopped using it! Now I use!
Code:
# Then mail it away!
open(MAIL, "|/usr/sbin/sendmail -t");
print MAIL "To: $to\n";
print MAIL "From: $from\n";
print MAIL "Subject: $subject\n";
print MAIL "\n";
print MAIL $msg;
close(MAIL);

BUT If someone has a better sullution, please post it here!
Quote Reply
Re: &html_validate_email (%{$links{$id}}) In reply to
DS, Now you mention it: I have the feeling Mailer.pm can handle large mails, so I hope you idee will help me out!

I'll implement it tonight. Thanks.