Posted by cover on 06/02/07 14:58
My form processes the lines below just fine so long as there's
something in the cc field (which I'm trying to leave optional). If the
cc field of the form is left blank, I get an error. I need an if
statement where the cc is optionally blank and the $to still works. As
I have it, the $to line below works well because there's always going
to be an entry however again, the cc won't be used 100% of the time.
I was toying around with the if statement below but don't have it
figured out yet. Any help is appreciated. TIA
$mail->AddAddress($arrEmailAddress[$to]);
$mail->AddCC($arrEmailAddress[$cc]);
----------code below clearly not there yet for the cc field-----------
if ($cc=''''){
$mail->AddCC($cc);
}
Navigation:
[Reply to this message]
|