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

  • SEARCH
  • Home
  • 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 3239532
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T17:58:52+00:00 2026-05-17T17:58:52+00:00

I use my webserver’s logs to count visits to my website. The software Webalizer

  • 0

I use my webserver’s logs to count visits to my website.

The software “Webalizer 2” displays these data in plain form with some diagrams.

But now I want to count visits by a special group of users separately. I have premium users and standard users. For premium users I want to have a separate statistics page so that I can see how many premium users’ hits there are.

How can I achieve that?

In my PHP script files, I detect the status as follows:

<?php
if ($_SESSION['status'] == 'premium') {
  // do something here
}
?>

The easiest way would – of course – be to have a MySQL update statement there to increment the premium users’ counter.

But that would also be a lot of database traffic. So I would prefer another solution.

I thought I could show a 1×1 pixels .gif image to the premium users. Then I could check the webserver’s statistics for the file “counter.gif”. BUT: I guess the client will cache the graphics file so my results won’t be correct, right?

Do you have an idea how to implement such a counter?

  • 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-17T17:58:53+00:00Added an answer on May 17, 2026 at 5:58 pm

    There are many solutions to this problem…

    If you use a 1×1 pixel gif and are worried about caching, do something like this:

    <img src="counter.gif?t=<?php echo time(); ?>" alt="" />
    

    But then you’d still have to have some tool on the backend to track, and then analyze this data.


    Alternatively Google Analytics has created simple ways to do this. Assuming you’re already using their tracking code, you can add a Custom Variable. See more here:

    http://code.google.com/apis/analytics/docs/tracking/gaTrackingCustomVariables.html#visitorLevel

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

Sidebar

Related Questions

I'm trying to use form editing on jqgrid. When the data is sent to
I am in mobile app. I use ajax calls to receive data from webserver
What can i use to send/receive data between an android client and a webserver.
I have my data on webserver in XML format. i want to use it
I am trying to use Sun java webserver (port 8099) as a Reverse proxy
On my webserver i am hosting 2 applications and both applications use the same
Whenever I use the following code, the webserver (running IIS 7) refuses to send
I have an apache webserver serving 2 URLs. I use VirtualHosts to configure it
I use MySQLdb a lot when dealing with my webserver. I often find myself
I use now thin to serve my rack application on my webserver. I have

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.