Gossamer Forum
Home : General : Perl Programming :

email problem

Quote Reply
email problem
i'm sure it's something simple but i just don't see it! i need a blank line in my email between the line that says "your userid is blah blah" and then the list of fields (@db_cols). but it's printing the first field on the same line as my userid. here's my code:

Code:
open (MAIL, "$mailprog") || &cgierr("Can't start mail program");
print MAIL "To: $rec{$db_email_field}\n";
print MAIL "From: $admin_email\n";
print MAIL "Subject: $my_subject\n\n";
unless ($record_notify_add == 1) {
print MAIL "$record_notify_add\n\n";
}
print MAIL "$my_message\n\n";
if ($auth_signup || $spec_signup ) { # added if... 2/21/2008
print MAIL "Your UserID is $rec{'Userid'}";
}
print MAIL "\n\n"; # HERE'S WHERE I WANT BLANK LINES
foreach $col (@db_cols) {
next if ($db_form_len{$col} < 0);
if ($rec{$col}) { print MAIL "$col -- $rec{$col}\n"; }
}
close (MAIL);
Quote Reply
Re: [delicia] email problem In reply to
Mmm, I don't see any reason why that shouldn't work!

If you change it to:

Code:
print MAIL "x \n\n y";

...do you see:

Code:
x

y

..in the email?

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] email problem In reply to
will try it later today. thanks
Quote Reply
Re: [delicia] email problem In reply to
it worked fine. i realized i was making changes in the wrong file Blush never use these emoticon; hope it means i'm embarrassed!

Last edited by:

delicia: Mar 10, 2011, 4:02 PM
Quote Reply
Re: [delicia] email problem In reply to
hahaha np ... been there, done that! Whistle

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!