Page 2 of 2

Re: email form attachment not working without the attachment

Posted: Mon Feb 01, 2010 3:56 pm
by social_experiment
The code below is what i receive when i send an email via the script. I attach a file, but it doesn't get sent.

Code: Select all

 
webmaster@example.com
MIME-Version: 1.0
Content-Type: multipart/mixed; 
boundary="_1_df6a564a3824fb8a39b172209cd33a22"
 
This is a multi-part message in MIME format.
  
 --_1_df6a564a3824fb8a39b172209cd33a22
 Content-Type: multipart/alternative; boundary="_2_df6a564a3824fb8a39b172209cd33a22"
  
 --_2_df6a564a3824fb8a39b172209cd33a22
 Content-Type: text/plain; charset="iso-8859-1"
 Content-Transfer-Encoding: 7bit
  
 
 Email = $email
 Name = $name
 Phone = $phone
 Occasion = $occasion
 Age = $age
 Flavor = $flavor
 Filling = $filling
 People = $people
 Month = $month
 Day = $day
 Delivery = $delivery
 Text = $text
  
 --_2_df6a564a3824fb8a39b172209cd33a22--
 --_1_df6a564a3824fb8a39b172209cd33a22
 Content-Type: application/octet-stream; name=""
 Content-Transfer-Encoding: base64
 Content-Disposition: attachment
  
 
 
 --_1_df6a564a3824fb8a39b172209cd33a22--
 
I also receive the following error when running the script (even though the mail is sent)

Warning: file_get_contents() [function.file-get-contents]: Filename cannot be empty in EmailSend.php on line 44

Are you receiving something similar?

Re: email form attachment not working without the attachment

Posted: Tue Feb 02, 2010 2:32 pm
by wak0
when i attach a file, it does reach the email, but when i dont have an attachment, i get that error.

Re: email form attachment not working without the attachment

Posted: Tue Feb 02, 2010 4:00 pm
by social_experiment
It might sound like bad coding practise but i'd suppress the error. Until i could figure out the problem.

Thank you

Posted: Thu Feb 04, 2010 1:18 pm
by wak0
Any luck