Well it is fine however take into consideration those
users who may visit your site could be on dial-up.

So per-say at 11:00AM you get Visitor A to come to your
site and you set the session.visitor since it was not set and the
IP Address was not present in your table.

Then at 1:00PM you get a different visitor lets call Visitor B
which is using the same ISP (Dial-up) and happens to have the
same IP as Visitor A, so you check the database table and see
the person has already visited the site considering the IP is present
which in fact this could be a brand new person.

Unless you are just trying to identify where you main traffic comes
from then this is fine, but to get an very close accurate Hit Couter
on new visitors it is a bit hard.

DAMN THEM DIAL-UPS...



----- Original Message -----
From: "Steve Oliver" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Sunday, January 27, 2002 8:39 PM
Subject: RE: CF and Hit Counter


> I don't see anything wrong with doing it that way.
> It won't cause any performance loss unless you get overloaded with hits
> all at once.
> But if your sites traffic generally comes from the same people, that way
> would work just fine.
>
> ______________________
> steve oliver
> cresco technologies, inc.
> http://www.crescotech.com
>
>
> -----Original Message-----
> From: Michael T. Tangorre [mailto:[EMAIL PROTECTED]]
> Sent: Sunday, January 27, 2002 8:35 PM
> To: CF-Talk
> Subject: CF and Hit Counter
>
>
> Hi all,
>
> I am in the process of writing a hit counter app in java, but in the
> meantime, I have thrown a little something together in CF and wanted to
> get some feedback on it.
>
> I have a SQL Server backend to this site and what I do is in the
> application.cfm page, I check for the existence of a variable called
> session.visitor. If it exists, it means that the application already ran
> the next part which is the code to look at the users IP and check for it
> in a table in my DB... if there is a match it sets the variable
> session.visitor again, and if no match is found it adds a record and
> then sets the variable.
>
> Is there anything wrong with the way I do this?...is there a more
> efficient way?
> Just so you know, I am unable to use cookies on this site.
>
> Mike
>
>
>
> 
______________________________________________________________________
Get Your Own Dedicated Windows 2000 Server
  PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation · $99/Month · Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusionb
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to