Stop Freeform from uploading file to server directory but still attach the file to the notification email?
Posted: 19 February 2008 08:56 AM   [ Ignore ]
Sr. Member
RankRankRankRank
Total Posts:  161
Joined  2007-02-19

This is kind of a follow up to my previous thread started here, but dealing with a different topic.

I’ve got a freeform in which I’m gathering info and then sending it to a moblog to be published to a weblog entry. The problem is that freeform is uploading the image to my server on submit and then once the moblog is checked, the image (attached to the email) is being uploaded yet again, so I’ve got two instances of this image being uploaded and I only need one.

Here is the code I’m using for my FreeForm:

{exp:freeform:form form_name="moblog-gallery-upload-form" notify="moblog@kentuckygolfing.com|dsizemore81@gmail.com" template="moblog-gallery-upload-form" send_attachment="yes" return="gallery/thank-you"}

   
<div class="contactField">
    <
label for="name">Your Name:</label> <span class="requiredField">(required)</span><br />
    <
input type="text" class="" id="name" name="name" />
   </
div>

   <
div class="contactField">
    <
label for="email">Your E-mail Address:</label> <span class="requiredField">(required)</span><br />
    <
input type="text" class="" id="email" name="email" />
   </
div>

   <
div class="contactField">
    <
label for="imageName">Image Name <span class="submitExample">(Example: "Valhalla Golf Club"):</span></label> <span class="requiredField">(required)</span><br />
    <
input type="text" class="" id="imageName" name="imageName" maxlength="27" />
   </
div>

   <
div class="contactField">
    <
label for="imageDescription">Image Description <span class="submitExample">(Example: "Hole 1"):</span></label> <span class="requiredField">(required)</span><br />
    <
input type="text" class="" id="imageDescription" name="imageDescription" maxlength="27" />
   </
div>

   <
div class="contactField">
    <
label for="subject">Upload Your Image:</label> <span class="requiredField">(required)</span><br />
    <
input id="imageFile" type="file" name="file1" />
   </
div>

   <
div class="contactField">
    <
input type="submit" name="Submit" value="Submit" class="submit" />
   </
div>

   
{/exp:freeform:form}

What I’ve done is removed the upload destination parameter from the freeform tag so that the image isn’t uploaded to the server, but I’d still like the file attachment to be attached to the email notification, but it doesn’t seem to be working correctly? I’ve got the “sent_attachment” parameter set to yes, but it still doesn’t attach the image to the notification email.

Can someone explain what I’m doing wrong? Does the send attachment parameter only work with the “upload” parameter in the freeform tag?

Profile
 
 
Posted: 19 February 2008 03:14 PM   [ Ignore ]   [ # 1 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  3717
Joined  2006-10-18
deronsizemore - 19 February 2008 08:56 AM

Does the send attachment parameter only work with the “upload” parameter in the freeform tag?

That is correct…

 Signature 

Check out the new Solspace Blog!

Profile
 
 
Posted: 19 February 2008 03:19 PM   [ Ignore ]   [ # 2 ]
Sr. Member
RankRankRankRank
Total Posts:  161
Joined  2007-02-19

Well crap, I was afraid of that. smile

I guess I can’t use freeform and moblog in this fashion then…at least when an image is involved anyway.

thanks.

Profile
 
 
Posted: 19 February 2008 03:20 PM   [ Ignore ]   [ # 3 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  3717
Joined  2006-10-18

Sorry about that wink

 Signature 

Check out the new Solspace Blog!

Profile
 
 
Posted: 19 February 2008 03:21 PM   [ Ignore ]   [ # 4 ]
Sr. Member
RankRankRankRank
Total Posts:  161
Joined  2007-02-19

Ah, no problem at all. I still love you guys/gals. smile

Profile
 
 
Posted: 20 February 2008 06:24 AM   [ Ignore ]   [ # 5 ]
Member
Avatar
RankRankRank
Total Posts:  73
Joined  2006-05-10

Hiya,

For anyone else following this I just posted here at http://www.solspace.com/forums/viewthread/641/. I’m hoping that is the answer? grin

Best wishes,

Mark

Profile