Thanks for the heads up Cristián.Yea, this Hook is misleading, it's not the right one to use in this case. Sorry for any confusion in the name of this Hook, but this Hook is really only fired in special cases, which may occur whenever a download attempt is being re-routed in some way; not useful in this case though.
In fact, I wouldn't Hook into the s2Member download routine at all
( at least, not to perform a redirection ), because it could interfere with a successful delivery of the file itself. Instead, you might consider spawning a new window, or doing something else creative with the link itself. For instance, with Google Analytics, I recommend one of these methods:
Reference articles:http://www.google.com/support/analytics ... swer=55529http://www.google.com/support/googleana ... swer=55527http://www.goodwebpractices.com/roi/tra ... cally.htmlAll of this being said, we are planning to create an API Notification for File Downloads, which will make new things possible, such as automatic email notifications and custom scripts that can receive the event as well. Look for this come to come in a future release. Until then, if you'd like to add this type of funcntionality yourself, you might try this Hook:
ws_plugin__s2member_during_file_download_accessAlso see documentation:
viewtopic.php?f=40&t=9134&src_doc_v=110605#src_doc_ws_plugin__s2member_during_file_download_access