Track file downloads?

Author Message

Daniel Guerrier

Wednesday 25 January 2006 9:48:52 am

I would like to create a feature where one user can see what files were downloaded by another user, but those files are part of a content object. The default download functionality only tracks how many times a file download was done. Can someone provide some insite as to how to track what was downloaded by a user but relative to the content object that is holding the file. Or how to create my own download functionality that records what content object the file is being accesed from and from what user session.

I will galdly except pointers to documentation that gives an idea on how to do this.
I looked far and wide and did not find any.

Thanks!!

Daniel Guerrier

Thursday 26 January 2006 7:03:00 am

Hoping that someone has looked at this.
Can someone chime in with a suggestion?

Daniel Guerrier

Thursday 26 January 2006 12:49:47 pm

Just keeping this on top in hopes that someone takes the time to look at it.

Ɓukasz Serwatka

Friday 27 January 2006 12:39:56 am

Hi Daniel,

You will need to track user id who download the file, and contentobject_attribute_id of this file (use new table). You can make your own download handler and a template operator which displays / fetches this information. Look on examples in eZ publish kernel/classes/binaryhandlers. This can be very nice contribution ;)

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Daniel Guerrier

Friday 27 January 2006 12:25:04 pm

How would I associate the file with the content object that it is contained in?

Thanks.

Leif Arne Storset

Saturday 28 January 2006 1:43:57 pm

I have the exact same need to log file downloads by users. I would love to develop an extension, but am unable to find any information on how to create a custom binary file handler. Any pointers, Lukasz?

My idea is to extend the class eZFilePasstroughHandler [sic] and simply override handleDownload(...), calling the superclass's function before or after logging the download. But how to register this new handler class?

Leif Arne Storset

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.