Forums

adding an attachment

mrwild 16 Jul, 2013
I cant figure out how to add an attachment to the email.
below is the debug code... it just shows the attachment as an empty array... I have no idea!!!!... thanks




[_PLUGINS_] => Array
(
[upload_files] => Array
(
)

)

)

Validation Errors:

Array
(
)
GreyHead 16 Jul, 2013
Hi mrwild,

What is the rest of the Debugger output?

There are no files being uploaded here. Have you checked the FAQs on uploading and attaching files?

Bob
mrwild 17 Jul, 2013
ok so i put some debugging code and file is uploading which is great however,,,,,,,, i cant get the link or the code that shows the image preview to work,,, I put the following code in to make the link :: <a href='{_PLUGINS_.upload_files.fileField.link}' >{_PLUGINS_.upload_files.fileField.name}</a> the field label is fileField, and it shows this in the email html of the email i receive {_PLUGINS_.upload_files.fileField.name} so its not showing the link to the download in the email thanks
mrwild 17 Jul, 2013
in terms of the faq I am finding it very hard to see how to add the link in the email or put the file as an attachment I did figure out how where the file field labels which is where i was going wrong
mrwild 17 Jul, 2013
[Receptiontime2] => 
[Numberofguests] => 
[Numberofinvites] => 
[Numberofguests2] => 
[Numberofguests3] => 
[textarea] => 
[button] => Submit
[6b9d5b80be24fe4759606ecf30a6adbf] => 1
[fileField] => 20130717173205_LETTERGESH.jpg
[_PLUGINS_] => Array (
  [upload_files] => Array (
    [fileField] => Array (
      [name] => 20130717173205_LETTERGESH.jpg
      [original_name] => LETTERGESH.jpg
      [path] => /home/ellief/public_html/components/com_chronoforms/uploads/enquiryform/20130717173205_LETTERGESH.jpg
      [size] => 511224
      [link] => http://elliefont.com/components/com_chronoforms/uploads/enquiryform/20130717173205_LETTERGESH.jpg
      )
    )
  )
  [IPADDRESS] => 122.149.237.120
)

Validation Errors:

Array()
---------------------------------------------------------------------------
further down i see :::     

{fileField}
{fileField2}

{_PLUGINS_.upload_files.fileField.name}

Submitted by 122.149.237.120
GreyHead 17 Jul, 2013
Hi mrwild,

Do you have the Upload Files action *before* the Email action?

Bob
mrwild 17 Jul, 2013
beautiful!!!!!! i love it!!! i moved the ordering and I get the attachment and the link i am though getting an error message Warning: array_values() expects parameter 1 to be array, null given in /home/ellief/public_html/administrator/components/com_chronoforms/form_actions/email/email.php on line 205

Warning: Invalid argument supplied for foreach() in /home/ellief/public_html/administrator/components/com_chronoforms/form_actions/email/email.php on line 206
GreyHead 17 Jul, 2013
Hi mrwild,

I'm not sure exactly what causes those but if you set Error Reporting to System Default or None in the site Global Configuration that should hide any PHP Warnings.

Bob
mrwild 18 Jul, 2013
thanks, great actually
This topic is locked and no more replies can be posted.