Collect Email then auto download file...

User 379172 Photo


Registered User
2 posts

Does anyone know how to use WFB to collect Name and Email from a site visitor then automatically send that visitor a free ebook? I've searched this forum without finding any autodownload function. Thanks in advance.
User 2147626 Photo


Ambassador
2,958 posts

There is no auto-download in WFB. At least not yet :D

You could do several things for the auto-download... you could just include a 'link' in the conformation e-mail you send the user. Just put something on the form stating that they will receive the download link in an e-mail.

Or here is a free script... http://www.stadtaus.com/en/php_scripts/download_center_lite/
Graphics for the web, email, blogs and more!
-------------------------------------
https://sadduck.com
User 187934 Photo


Senior Advisor
20,271 posts

You could also take a look at Coffeecup's Lockbox. It would be awesome if they made some kind of direct integration script to work with the form builder. You should be able to use the confirmation to share the file with the user.:cool:
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 464893 Photo


Ambassador
1,611 posts

Here Adrian redirect to this script. I have not tried it but it will find the last entry in a csv file, you set the position of the email address starting with zero. Create a file whatever.php to redirect to, it extracts the address emails and should display the link to be clicked on.

<?php
error_reporting(E_ALL & ~E_NOTICE);
$file_handle = fopen("http://phpsnippets.webatu.com/Decision/storage/csv/results.csv", "r");// the address where the file is located
while (!feof($file_handle)){
$item = fgetcsv($file_handle, 1024);
if($item=="")Break;// make sure the last entry is used
$lastitem=$item;

}
fclose($file_handle);
$email= $lastitem[*];//* is the position of email starts with 0 then 1 etc. <<<<<<
$message="link to download";// add download link
//send mail

$subject="ebook";
$email = $email;
$message=$message;
$send_mail = mail($email,$subject,$message);
if ($send_mail)

?>


I am gradually assembling some code to explore for back ends to forms, When I finish a current project I am on I will test and refine the scripts I am collecting.
The Guy from OZ


User 187934 Photo


Senior Advisor
20,271 posts

Thanks Prism. Our resident csv expert comes through again.:cool:
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 38401 Photo


Senior Advisor
10,951 posts

All this hassle, wouldn't it just be way easier to include that in the reply email when someone fills out the form? Alter your reply email code and add that part in there with the link and you're done. No emails needing to be grabbed and sent to and redirected etc. Just a thought :)
User 2147626 Photo


Ambassador
2,958 posts

You could do several things for the auto-download... you could just include a 'link' in the conformation e-mail you send the user. Just put something on the form stating that they will receive the download link in an e-mail.


Kind of thought that was what I suggested at the start of all this :P
Graphics for the web, email, blogs and more!
-------------------------------------
https://sadduck.com
User 103173 Photo


VP of Software Development
0 posts

Or you could just redirect to a custom page that has a meta-refresh which includes the PDF file.
Learn the essentials with these quick tips for Responsive Site Designer, Responsive Email Designer, Foundation Framer, and the new Bootstrap Builder. You'll be making awesome, code-free responsive websites and newsletters like a boss.
User 38401 Photo


Senior Advisor
10,951 posts

yeah that's why I posted, because it's the simplest solution and he seemed to not see it or realize it maybe?
User 2147626 Photo


Ambassador
2,958 posts

I don't think the original poster has checked back in since this thread started.
Graphics for the web, email, blogs and more!
-------------------------------------
https://sadduck.com

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.