Closed DanielSiepmann closed 2 years ago
EXT:tracking could further provide a mechanism to check whether the URL should be altered, e.g. like bot detection. That would allow integrators to configure which urls should be tracked. We would only modify those matching URLs and prevent potential issues with others.
This was an request by a company. It won't make it right now as company won't sponsor.
Feel free to comment an re open issue in case you are interested in this feature.
Some websites provide specific files for downloads, e.g. flyers or press material. The owners might be interested in how often a file was downloaded.
That should be part of this extension.
The following Event should be a solution https://github.com/TYPO3/typo3/blob/10.4/typo3/sysext/core/Classes/Resource/Event/GeneratePublicUrlForResourceEvent.php which could be used. The idea: Alter URL and extend existing Recordview Middleware. It will detect the file and add a recordview for that file record. A new default widget configuration should be provided to show file downloads based on that data. The widget already exists, as we use recordview: https://docs.typo3.org/p/danielsiepmann/tracking/1.1/en-us/RecordviewWidgets/Recordviews.html.
That might not be compatible with other extensions like https://extensions.typo3.org/extension/secure_downloads. That would be an extra feature per extension, as all of them might work differently. We would need to check whether they are installed and alter flow.
The Event is available since 10 LTS: https://docs.typo3.org/c/typo3/cms-core/master/en-us/Changelog/10.2/Feature-89577-NewPSR-14BasedEventsForFileAbstractionLayer.html
I would estimate the effort of around half a day up to one day.