How does UserScripts Track Number of Script Downloads??

Subscribe to How does UserScripts Track Number of Script Downloads?? 6 posts, 4 voices

 
rahul286 Scriptwright

Guys,

Please can anyone tell me how download stats for each script has been tracked!

Actually I scripts have absolute download link... Then how server keeps track of no.of download??

Is there any special script or program running on server???

Waiting for some answer...

-Rahul :-)

 
zzo38 Scriptwright

Probably it just checks how many times that file is requested

 
Mikado Scriptwright

The counter is going up every time the install link is used (http://userscripts.org/scripts/source/####.user.js), even if user doesn't actually install it or already has that script. If you want to get script file without incrementing install counter, you might use "view as plaintext" link: http://userscripts.org/scripts/review/####?format=txt.

 
psyched Scriptwright

Iirc, the counter only goes up if you're logged in and are viewing the script.

 
rahul286 Scriptwright

No psyched... Counter goes on incrementing whenever someone accesses script with URL ending .user.js extension...
Act I have seen download tracker where a file is kept on a sever say download.php, then all URL rewritten like download.php?url="original_url"
Then download.php usually updates a database table for entry "original_url"

This way URLs on site redirected. I hate this approach as its not fullproof. Also redirection is visible and makes URL dirty! :-(

So thats why I was wondering about userscripts way of tracking file downloads!

 
psyched Scriptwright

Right, I actually tested that once, sorry about that :)
But there was something about needing to be logged in to do something...