Page 1 of 1

send email after downloading a file?

Posted: 2010-05-11 15:37
by piripacchio
Hi all,
I built a little file management system using MX Kollection 3 pro.
A logged user can upload or download a file.
I can easily add the send email behaviour when uploading a file.
But, is there a way to send an email after downloading a file?

TIA
tony

Re: send email after downloading a file?

Posted: 2010-05-12 13:10
by Fred
Haven't done it before but I would imagine you would need a custom transaction similar to this one listed here http://www.interaktonline.info/article/ ... -site.html

It would obviously need some hand coding and I would assume you would ad a third line after the following code:

// Download File downloadObj1
$downloadObj1 = new tNG_Download("", "KT_download1");
$downloadObj1->setConnection($conn_SiteConn, "SiteConn");
$downloadObj1->sendEmail(something) // Call your custom function

Re: send email after downloading a file?

Posted: 2010-05-17 11:12
by piripacchio
Fred wrote:Haven't done it before but I would imagine you would need a custom transaction similar to this one listed here http://www.interaktonline.info/article/ ... -site.html
Thanks Fred,
but I cannot add a custom trigger to the nextensio list. I get an error saying there is no insert/update/delete transaction on page.

Is there a workaround to add it anyway?

tia

tony

Re: send email after downloading a file?

Posted: 2010-05-17 11:45
by Fred
You are right, it is dependant on a transaction.

Think I have a very crude way that could work.
Change the download link to a checkbox confirming something like "I agree with download Terms" or something.
When clicked open a new page with the download link and use the "Send Page by Email" behaviour?