Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 528757
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T09:01:11+00:00 2026-05-13T09:01:11+00:00

I have a Drupal website where users are clicking on a link that initiates

  • 0

I have a Drupal website where users are clicking on a link that initiates a file download from a content delivery network (CDN). A script is tracking the number of users who click the link to begin the download process. I’m looking for suggestions on how I might track the number of users who successfully complete the download process.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T09:01:12+00:00Added an answer on May 13, 2026 at 9:01 am

    If you only need the number of completed downloads, just grab the raw logs from your CDN and run them through a log analysis tool. Most CDNs provide daily access logs as a standard service. The bigger players can do hourly logs or better.

    The best solution will depend on your CDN, so talk to them if you haven’t already. However, here’s how I’ve done it in the past.

    To each protected download URL generated, append a unique id for the user who made the request. A typical CDN download URL might contain an expiry time and a hash to prevent tampering. You’ll want to check with your CDN first to make sure you pick a variable name that doesn’t clash with their API. In our case we agreed on a prefix of ign_* (meaning ignore.)

    Before:

    http://cdn.example.com/path/to/file.ext?e=EXPIRES&h=HASH
    

    After:

    http://cdn.example.com/path/to/file.ext?e=EXPIRES&ign_u=USERID&h=HASH
    

    Example (download link for user 1234):

    http://cdn.example.com/path/to/file.ext?e=1356088260&ign_u=1234&h=39341385b9d99730646d927f620111e1
    

    Now when you download your raw logs, each entry can be associated with one of your users simply by parsing the query string. From here you can do everything from counting the number of completed downloads, to implementing per-user download reports.

    In our case, we had logs available every 15 minutes and I automated the fetching and processing to enable byte-level per-user download quotas.

    One thing to keep in mind, if you’re going to be processing the logs yourself, is to group HTTP 206 partial entries together. Particularly if you’re interested in the “number of completed downloads.”

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Flash application that is hosted from within a Drupal page. Some
I want to accomplish the following scenario in Drupal: You have 2 content-types. Lets
I have Drupal 5 site where a button is clicked and it calls a
I have a Drupal module page where I am populating a form with a
I need a very quick fix in a mod_rewrite expression for drupal we have
I have the occasion to produce Drupal web sites using development, staging, and production
I am finishing up a Drupal site and I have attached a word document
Have just started using Google Chrome , and noticed in parts of our site,
Have you ever seen any of there error messages? -- SQL Server 2000 Could
Have you guys had any experiences (positive or negative) by placing your source code/solution

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.