We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Linklocker Free (encrypt download links)

Development and Programming

Ryan M.'s avatar
Ryan M.
1,511 posts
16 years ago
Ryan M.'s avatar Ryan M.

Can this track download counts in any way? Or can it work in conjunction with another module or plugin (suggestions welcome) that can track downloads? I desire two things for my downloads on this build: hide the real download location, and track the number of downloads. Ideally it also tracks who downloaded it as well, so you’d know if you have already downloaded a certain file or not. Thanks!

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen

Hi Ryan,

You could perhaps use the AJAX Link Tracker. Pretty sure that would work, maybe? 😉

Best wishes,

Mark

       
Brad Street's avatar
Brad Street
239 posts
16 years ago
Brad Street's avatar Brad Street

The module does not currently support counting downloads, nor does it support tracking downloads ( for example, on a per-user basis) as in your question. I’ll look this evening and see what may be involved in extending the module to include this sort of functionality.

       
Ryan M.'s avatar
Ryan M.
1,511 posts
16 years ago
Ryan M.'s avatar Ryan M.

As Mark pointed out, I may be able to use Silenz’s Link Tracker to track the links, but I’d need to modify it a bit to store the id of the user who downloaded the file (if they were logged in), otherwise store a zero or something. I’m looking to make it so a user can keep track of those files they have downloaded and see them at a glance.

       
Ryan M.'s avatar
Ryan M.
1,511 posts
16 years ago
Ryan M.'s avatar Ryan M.

I’d prefer an all-in one solution for protection/tracking, and I think mashing this together with the Linktracker functionality wouldn’t be too tough (and I don’t think I need the AJAX part - just insert into the DB when the file is dished to the user). I might try frankensteining them together myself.

Basically I’d need another table created when installing Linklocker - similar to the table Silenz creates to store click info, but allowing for user_id in a column.

Then, I think I’d need to insert the click info into the table right around line 164 in mod.linklocker.php:

$this->return_data = $FNS->fetch_site_index(0, 0).'?ACT='.$action_id.'&url=1'.'
&linklocker='.$output;
$sql = "INSERT INTO exp_track_linkloks (link_id, stamp, target, url, label, ip) VALUES ('$id','".mktime()."','$target','$url','$label','$ip');";
            $DB->query($sql);

A new parameter asking whether the link even should be tracked would be cool, too.

{exp:linklocker url=”/music/SomeSong.mp3” expires=”10” iplock=”off” track=”off” err_page=”{path=download/error}”}

Something like that :-)

       
Ryan M.'s avatar
Ryan M.
1,511 posts
16 years ago
Ryan M.'s avatar Ryan M.

For now, I’m using this in conjunction with the link tracker Mark mentioned - but just to do a real basic count at this point. My code looks much like this inside a weblog:entries tag:

<a href="http://{exp:linklocker">Download {title}</a>


Downloads: {exp:linktracker:clicks link_id="vc2_{entry_id}"}
       
Brad Street's avatar
Brad Street
239 posts
16 years ago
Brad Street's avatar Brad Street

Ryan,

Thanks for the helpful input - will begin working on an update to include counts today.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen
Ryan, Thanks for the helpful input - will begin working on an update to include counts today.

Can I just be the first to say what an amazing guy Brad is? 😉

Talk about support.

Brad you sir are a true gent and your module just keeps on getting better and better every single day 😊

Take it easy now as we don’t want you burning out on this 😉

Best wishes,

Mark

       
monteconsulting's avatar
monteconsulting
35 posts
16 years ago
monteconsulting's avatar monteconsulting

Just chiming in to agree with Mark about Brad’s work, and that I’m really excited to see a version of this that tracks downloads, especially if it can do so with logged-in user tracking. Good stuff!

       
Brad Street's avatar
Brad Street
239 posts
16 years ago
Brad Street's avatar Brad Street

Thanks for the kind words of encouragement all. Been toying with it all day (so much for my day job!) - hope to have something out in the next couple of days.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen

Now that’s what I call fast!! 😉

You really are a very kind man sir. 😊

Best wishes,

Mark

       
Brad Street's avatar
Brad Street
239 posts
16 years ago
Brad Street's avatar Brad Street

Just wanted to post an update. The coding I have been doing has unfortunately resulted pretty much in a complete rewrite of the module, and the addition of a companion plugin. The rewrite was significant enough that the new version will be v. 2.0, and will require a small licensing fee. Version 1.4 will remain free for business & personal use for the foreseeable future, though it will not likely see further development.

The coding is pretty much complete on LinkLocker v.2 and I’m testing now - will likely spend the weekend ironing out any bugs that crop up. Hope to post over the weekend or on Monday about all the new functionality.

       
Mark Bowen's avatar
Mark Bowen
12,637 posts
16 years ago
Mark Bowen's avatar Mark Bowen

Sounds great Brad. Fee is totally understood as the module as it stands now is a fantastic piece of work.

Looking forward to hearing all about the new versions functionality.

Have a great weekend.

Best wishes,

Mark

       
Ryan M.'s avatar
Ryan M.
1,511 posts
16 years ago
Ryan M.'s avatar Ryan M.
Just wanted to post an update. The coding I have been doing has unfortunately resulted pretty much in a complete rewrite of the module, and the addition of a companion plugin.

Not necessarily anything wrong or unfortunate about that, I don’t think! I bet it’s better all around.

The rewrite was significant enough that the new version will be v. 2.0, and will require a small licensing fee.

I’m sure no one will mind - you have a significant amount of work into this. I’m really looking forward to seeing what you’ve done.

The coding is pretty much complete on LinkLocker v.2 and I’m testing now - will likely spend the weekend ironing out any bugs that crop up.

DM if you want another tester. I have two real life scenarios I can test/use this on right now.

       
monteconsulting's avatar
monteconsulting
35 posts
16 years ago
monteconsulting's avatar monteconsulting

Awesome Brad, I’d be more than willing to pay for functionality that protects and tracks downloads.

       
First 8 9 10 11 12 Last

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.