typo3eula

Show license agreement before download


I have to solve the following task for our university homepage:

I searched through the extensions but did not find any extension doing the job. Maybe you know one...

So I tried to implement my own extension. Taking the strengths of securelinks (Allows access control to files from a configurable directory ... presents a license acceptation prior to download) and naw_securedl ("Secure Download": Apply TYPO3 access rights to ALL file assets (PDFs, TGZs or JPGs etc. - configurable) - protect them from direct access.) I wanted to combine both extensions to have one that:

  1. whenever a pdf file is requested (naw_securedl)
  2. a license is shown and in case of ACCEPT a redirect to the file happens (securelinks).

This task sounds very easy, since I only have to combine both tasks. Anyway, I failed.

How do you solve this problem? Do you know some extension doing the job? Is anyone interested in a cooperation in which we try to create an extension thats doing the job?

Thanks for your help in advance!


Solution

  • Assuming that all donwloads are stored in one folder, I'd recommend writing your own little extension that replaces every link with a link to an intermediate site, like this:
    www.mydomain.com/acceptlicense.html?downloadfile=myhighqualitycontent.pdf.

    On the accept license page, users need to check the accept license checkbox, then click a submit button, which leads them to the download page, still carrying the GET parameter: www.mydomain.com/download.html?downloadfile=myhighqualitycontent.pdf.

    If not all files are in the same folder, you can replace slashes in the file path with other characters (they need to work in the URL). Or you might need a database table that indexes the files, so you can use IDs for the download files:
    www.mydomain.com/acceptlicense.html?downloadfileID=99

    If you don't know at all how to write TYPO3 extensions, consider using individual php/html files out of the TYPO3 context.