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 389873
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T15:54:33+00:00 2026-05-12T15:54:33+00:00

Tried to find answer here but, no luck so, here goes; I would like

  • 0

Tried to find answer here but, no luck so, here goes;

I would like the ability to log a specific images “hits” or even just a log file that reports all image loads of all images (w/individual stats) that reside in a specific folder.

I DO NOT want to serve images on a remote server via a script e.g. <img src=image.pl?thisone> . I just want the ability to use a standard image tag.

I even thought of using htaccess RewriteRule with ^<img but, beyond my understanding / experience with htaccess. I just use it to conceal my sites structure a little and some level of protection. (thanks to ultimate htaccess).

I have torn through apps like awstats (which I actually like) and found tons of bulkware “solutions” that offer far too much. I just cannot find a snippet containing a clue.

I just need to log how many times that image was loaded into someones browser. If I can get a few more details that would be fine but, really just need an image impression hit counter.

This would allow me to make a quick stats page for a local artist friend I am making a simple site for. He could then just hit a stats page and check the stats on his images views. Tracking clicks are no problem (the img is wrapped in a link to his site).

I searched cpan for a module to install to no avail. Obviously PERL is my pref here but, any solution that gets me going is appreciated. I spent all day trying to figure this one out.

Thanks in advance..

  • 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-12T15:54:34+00:00Added an answer on May 12, 2026 at 3:54 pm

    you can use htaccess to send *.jpg etc to a script , possible php or perl, that file would log the hit to the DB and then return the image.

    something like this

    Options +FollowSymlinks
    RewriteEngine on
    
    RewriteRule ^(.*).jpg$ image.php?name=$1 [L,NC]
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

tried to find the answer by googling and in MSDN but with no luck.
I feel kinda stupid, I tried to find an answer on here but couldn't
I've tried to find the answer to this question but none of the answers
I tried searching in google but could not find any useful answer, if(verifier.length() >
I've tried Google, but I can't find the answer to this simple question. I
I've tried searching on this but can't seem to find an answer anywhere, so
looked around here, but didn't find straightforward answer.. I'm using cookies, to store last
I tried to find the answer to my problem in the questions history but
I tried to find the right answer to my question but I couldn't, that's
I have tried to find answer to this question from the official docs, but

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.