IP collection

daz

Geek
Hello.
I am relatively new to JavaScript programming, and I was wandering is there a script that allow to collect IP addresses of visitors on my particular website for traffic measuring purposes only. I just want a clear view of traffic on my site.

But even more importantly I am interested in number of different users that are visiting my website, I just want my costume data. is it relatively possible to do?

Regards
Dariusz Krak
 
I don't think you can with Javascript, its usualy accessable via server side scripting.

e.g. PHP

PHP:
echo $_SERVER['REMOTE_ADDR'];

It can be mixed with javascript

HTML:
<script type="text/javascript">
alert("<?php echo $_SERVER['REMOTE_ADDR'] ?>");
</script>
 
Thank you. I have don some research in to the topic, and it is a lot more complex that I have previously anticipated.
 
Back
Top