Hello,
I'm using a script for sending email. Depending on the value of variable vacaturennummer I take an emailadress. This works. In the form are 2 uploads (field CV and motivatie).
Is it possible to send thease as an attachment with the email. This is the script I use:
global $mosConfig_mailfrom, $mosConfig_fromname, $my;
$this->execPieceByName('ff_InitLib');
$from = ff_getSubmit('email');
$fromname = ff_getSubmit('voorletters').' '.ff_getSubmit('achternaam');
$subject = 'Sollicitatie: '.ff_getSubmit('vacaturenummer').', '.ff_getSubmit('functie');
if (substr(ff_getSubmit('vacaturenummer'),0,1) <> 'Z') {
$recipient = '
This e-mail address is being protected from spambots. You need JavaScript enabled to view it.
';
} else {
$recipient = '
This e-mail address is being protected from spambots. You need JavaScript enabled to view it.
';
}
foreach ($this->maildata as $data) {
$body .= $data[_FF_DATA_TITLE].': '.$data[_FF_DATA_VALUE].nl().'';
}
$this->sendMail($from, $fromname, $recipient, $subject, $body); // This line acutally emails off the form.
$this->sendMail($recipient, 'Saxenburgh Groep', $from, $subject, $body); // This line acutally emails off the form.