Home > Archive > PHP Language > November 2004 > Simple information gathering script req..
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Simple information gathering script req..
|
|
|
| I'm after a *simple* script to log each visitor to a website. All
I actually need is the visitor's reported IP address whether
genuine, proxied or hidden. Their reported browser type would be
an advantage, regardless of what browser is actually used.
Anyone know of anything simple and preferably free that will do
this? The site is hosted on a FreeBSD server with access to
CGI-Bin but it does not seem to have a server-side stats log.
I am aware of the value (or not) of any information gathered by
such means, however I still require it. Just something to log the
information presented by each visit please.
Many thanks and regards,
Mike.
| |
| brucie 2004-11-22, 3:56 am |
| In alt.html,alt.comp.lang.php,comp.lang.javascript Mike said:
> I'm after a *simple* script to log each visitor to a website.
i know. see uk.net.web.authoring
What is the accepted way to share a message across multiple newsgroups?
http://smjg.port5.com/faqs/usenet/xpost.html
--
the facts and opinions expressed by brucies
l i t t l e v o i c e s
are not necessarily the same as those held by brucie.
| |
| King of Red Lions 2004-11-22, 3:56 am |
| Mike wrote:
> I'm after a *simple* script to log each visitor to a website. All
> I actually need is the visitor's reported IP address whether
> genuine, proxied or hidden. Their reported browser type would be
> an advantage, regardless of what browser is actually used.
>
> Anyone know of anything simple and preferably free that will do
> this? The site is hosted on a FreeBSD server with access to
> CGI-Bin but it does not seem to have a server-side stats log.
>
> I am aware of the value (or not) of any information gathered by
> such means, however I still require it. Just something to log the
> information presented by each visit please.
>
> Many thanks and regards,
> Mike.
http://www.alt-php-faq.org/local/24/
| |
|
| King of Red Lions <thaynes/no_spam/@gawab.com> wrote:
>Mike wrote:
[color=darkred]
>http://www.alt-php-faq.org/local/24/
Hmm.. Not sure if that's what I'm after, although the problem
might just be me being all newbie and thick. I'll have a read and
thanks anyway.
Mike.
| |
| Karl Core 2004-11-22, 3:56 am |
|
"Mike" <find@reply.to> wrote in message
news:300uihF2r3n0bU4@uni-berlin.de...
> brucie <shit@usenetshit.info> wrote:
>
>
> Seen and answered, hope you approve (sic).
>
>
> I'll play your XXXXing stupid game, go on then, what is the
> accepted way to share a message across multiple newsgroups?
Well, if you weren't such a dumbass, you'd have clicked on the link that
Brucie so kindly supplied to you and you'd have gotten the answer to that
question.
Here's a hint - if you're asking people for help, don't treat them like an
XXXXXXX and expect to get kindness in return. Remember, it is *you* who've
come here for help, not the other way around.
--
-Karl Core
Please Support "Project Boneyard":
http://www.insurgence.net/info.aspx...d&item=boneyard
| |
|
| "Karl Core" <karl@NOSPAMkarlcore.com> wrote:
>
>"Mike" <find@reply.to> wrote in message
>news:300uihF2r3n0bU4@uni-berlin.de...
>
>Well, if you weren't such a dumbass, you'd have clicked on the link that
>Brucie so kindly supplied to you and you'd have gotten the answer to that
>question.
Are you serious? You are serious aren't you! rofl.
>Here's a hint - if you're asking people for help, don't treat them like an
>XXXXXXX
Bzzzzt americanism detected.. can't translate.. abort.. bzzzzt!
Ahh.. That's why you didn't understand my other post, irony is
lost on you lot isn't it.
Here's a hint: I have received other quite reasonable responses
to which I have replied with similar reasonableness and offered
my gratitude to. Now go ask yourself why you think I would
respond differently to our "brucie".
When you get stuck (as you inevitably will), click this;
<11jtlzddkxj7f$.dlg@usenetshit.info> and this;
<1fft5ouhclfbf.dlg@usenetshit.info>
hth.
| |
| Disco Octopus 2004-11-22, 3:56 am |
| Mike typed:
> I'm after a *simple* script to log each visitor to a website. All
> I actually need is the visitor's reported IP address whether
> genuine, proxied or hidden. Their reported browser type would be
> an advantage, regardless of what browser is actually used.
>
> Anyone know of anything simple and preferably free that will do
> this? The site is hosted on a FreeBSD server with access to
> CGI-Bin but it does not seem to have a server-side stats log.
>
> I am aware of the value (or not) of any information gathered by
> such means, however I still require it. Just something to log the
> information presented by each visit please.
>
> Many thanks and regards,
> Mike.
maybe you can make something of this.... do you have access to php?
place it in a standard included header file or somthing...
<?php
$logFile = "log.txt";
$logRec = "REMOTE_ADDR=". $_SERVER["REMOTE_ADDR"] . ",
HTTP_USER_AGENT=" . $_SERVER["HTTP_USER_AGENT"];
$logRec .= "\n";
$logFP = fopen ($logFile, 'a');
fputs ($logFP, $logRec);
fclose($logFP);
?>
| |
|
| added news:uk.net.web.authoring
"Disco Octopus" <discooctopusN05PAM@yahoo.com> wrote:
>Mike typed:
[color=darkred]
>maybe you can make something of this.... do you have access to php?
Yes, the site is hosted in a *nix environment so I assume it will
work.
>place it in a standard included header file or somthing...
>
><?php
> $logFile = "log.txt";
> $logRec = "REMOTE_ADDR=". $_SERVER["REMOTE_ADDR"] . ",
>HTTP_USER_AGENT=" . $_SERVER["HTTP_USER_AGENT"];
> $logRec .= "\n";
> $logFP = fopen ($logFile, 'a');
> fputs ($logFP, $logRec);
> fclose($logFP);
>?>
That is excellent and it worked!!! Thank you, thank you, thank
you, thank you, thank you, thank you, thank you, thank you, thank
you, thank you, thank you, thank you.. etc.
It would be better if it worked in a html page mind. As I
understand it, google prefers .html pages for indexing, so this
can't be used in the home page.
But thank you, it is certainly good enough. :-)
Regards,
Mike.
| |
| Geoff Berrow 2004-11-22, 3:56 am |
| I noticed that Message-ID: <3014hnF2peot0U1@uni-berlin.de> from Mike
contained the following:
>That is excellent and it worked!!! Thank you, thank you, thank
>you, thank you, thank you, thank you, thank you, thank you, thank
>you, thank you, thank you, thank you.. etc.
And you think that $_SERVER['REMOTE_ADDR'] is giving you the IP of the
person accessing your page huh?
Ah well, as long as you're happy.
--
Geoff Berrow (put thecat out to email)
It's only Usenet, no one dies.
My opinions, not the committee's, mine.
Simple RFDs http://www.ckdog.co.uk/rfdmaker/
| |
|
| Geoff Berrow <blthecat@ckdog.co.uk> wrote:
>I noticed that Message-ID: <3014hnF2peot0U1@uni-berlin.de> from Mike
>contained the following:
>
>
>
>And you think that $_SERVER['REMOTE_ADDR'] is giving you the IP of the
>person accessing your page huh?
No.. The actuall IP is not important, just as long as I get stats
that show an IP for each visit.
Is is *impossible* to guarantee the ID of visitors to a website.
Imagine if everyone visited via aol.com, guardster.com,
anonymiser.com or any one of the more dubious offerings from
places like stayinvisible.com.. Such stats would be useless if
relied upon for actual identification.
However, many people do not know of such facilities, or even why
they might use them, and so some stats will give an indication of
where *some* traffic originates.
This is all I am after:
1.) How much traffic.
2.) Where does it claim to originate
3.) What is the claimed browser (not essential).
All I need is the numbers, I have said this repeatedly.
>Ah well, as long as you're happy.
It's a start.
| |
| Matt Bradley 2004-11-22, 3:56 am |
| Geoff Berrow wrote:
> I noticed that Message-ID: <3014hnF2peot0U1@uni-berlin.de> from Mike
> contained the following:
>
>
>
>
>
> And you think that $_SERVER['REMOTE_ADDR'] is giving you the IP of the
> person accessing your page huh?
<http://www.phpfreaks.com/phpref/52.php>
Whether this is a person or a bot, whether that person is using a proxy,
or whatever, is another matter. But, yes, $_SERVER['REMOTE_ADDR'] will
give you the IP address of the requesting client.
--
Matt Bradley
"Myths which are believed in tend to become true"
-George Orwell
| |
|
| Matt Bradley <my_name_at@equaliser.net> wrote:
>Geoff Berrow wrote:
[color=darkred]
>
><http://www.phpfreaks.com/phpref/52.php>
>
>Whether this is a person or a bot, whether that person is using a proxy,
>or whatever, is another matter. But, yes, $_SERVER['REMOTE_ADDR'] will
>give you the IP address of the requesting client.
Indeed.. I have tested it via several different clients and it
works very well.
| |
| Alan J. Flavell 2004-11-22, 3:56 am |
| On Wed, 17 Nov 2004, Matt Bradley wrote:
> Whether this is a person or a bot, whether that person is using a proxy, or
> whatever, is another matter. But, yes, $_SERVER['REMOTE_ADDR'] will give you
> the IP address of the requesting client.
or proxy, or gateway.
| |
|
|
"Mike" <find@reply.to> wrote in message
news:303a57F2p7kfbU1@uni-berlin.de...
> "Richard Watson" <tinnedmeat@doilywood.org.uk> wrote:
<snip>
>
> Not sure no, it is one of those urban whispers but seems
> widespread enough to have some merit.
That's what it is, urban legend.
Google will happily take about almost anything unless you have gazillion
variables in dynamic page ulrs. More there are variables, more likely google
(or other searchbots) will spider slower or go only so deep to pages (to not
get in endless loop situations).
| |
| :::Jerry:::: 2004-11-22, 8:56 pm |
|
"Mike" <look@reply.to> wrote in message
news:3046c1F2s6rrmU3@uni-berlin.de...[color=darkred]
> ":::Jerry::::" <me@privacy.net> wrote:
<snip abuse>
Thanks for replying with your changed user ID, I suspect you have just
proved yourself to be the troll and man of self abuse many (I suspect) are
starting to think you are...
| |
|
| Mike <find@reply.to> wrote:
> Oh lol you twat.
Lol. LOL!!
Plonk!
|
|
|
|
|