I am trying to add file attachments on the notification emails sent out by sprout forms plugin. Looking in the docs it looks like I need to add hidden config setting within the plugin.

I have created a config.php file in the plugin directory and put the following code in it:


return array(

'sproutForms' => 'enableFileAttachments',


However, when I receive a notification email it still doesn't have the attachment. Can anyone suggest what I'm doing wrong?

  • Have you added enctype="multipart/form-data" to your <form> tag? Commented Jun 23, 2015 at 11:55
  • Hi Alec, yep I've added that to my form. Everything saves correctly, asset is uploaded,notification email is sent and shows the name of the file but the only thing not happening is the asset being attached to the email Commented Jun 23, 2015 at 11:58
  • I'm pretty sure it is to do with the config because of the message in the sprout forms log file: 2015/06/23 08:39:08 [info] [plugin] File attachments are currently not enabled for Sprout Forms. Commented Jun 23, 2015 at 12:03
  • Oh okay, instead of adding a config.php into the plugin folder, have you tried adding it to your general.php config? Commented Jun 23, 2015 at 12:07
  • Just tried that again but no luck I'm afraid Commented Jun 23, 2015 at 12:15

1 Answer 1


It looks like your on the right track but there may be a couple issues that we need to address:

  1. The hidden config setting should be set in the craft/config/general.php file

  2. The enableFileAttachments config setting should also be within an array and set to true:

    return array(
      'sproutForms' => array(
        'enableFileAttachments' => true,

Note: As of this posting, we handle this functionality as a hidden config setting because we are still refining it's behavior. At some point, this will likely be easier to do directly from the Control Panel.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.