Posted by bottticelli in I2P
Greetings, fellow ramblers.
I would like to ask you about the implementation of a simple user count for my eepsite (now being just a static HTML page). As far as I researched this question, for clearnet the situation is roughly as follows:
-
There is relatively easy way of doing this with JavaScript, which does not satisfy me since I do not want my eepsite working with JavaScript, it's nasty and collects too much data about the users. I personally hate JavaScript-demanding sites, even more do I dislike them in darkweb.
-
There are lots of free user counters available in clearnet, they say 'just sign up for free, even without email, and choose any design you want, then paste your URL here and we will do the rest'. Such solutions are obviously obnoxious since I have no control over the amount of information they would have been possessing, and certainly i2p link won't work with that (if I'm wrong here, please correct me). Maybe there are some good and transparent services for user count across the i2p network?
-
There is another way of creating a PHP script dealing with it, still relatively easy. Seems to be perfect, but I wonder if there are any simpler ways. To my knowledge, there is no way of performing this in HTML alone, since it has to be server-side (however, if I misunderstood something, again please do point me to my ignorance).
Apart from technicalities, I see one more interesting and subtle question here concerning the philosophy (let me take the liberty of using that term) of Invisible Internet. I am going to raise this question in a distinct submission soon, and I heartily encourage all of you to join the discussion. Meanwhile, please give me a hint about the forum where it could be the most relevant. AskRamble? I2P? Anonymity? Privacy? Whatever?
not_bob wrote
If you have a static site, you are limited to using someone else's counter. There is no way to run PHP code from a static site. Also, even if you were to use JavaScript, there is no way for your static site to store that data. So, still not an option.
The only real solution with such a site is to use someone else's counter as you mention in #2.
Not all I2P users have a clearnet outproxy configured. So, using a clearnet service is not the best option. Possible privacy issues aside.
I have a counter on the front of my notbob page. If you mouse over the van on the upper left side you will see a little box with a green graph. While it does not currently show the count, it still counts.
It would not be hard to write a multi-user count. I could likely code one up that would work for anyone pretty quickly. Something basic that just displays a number.
You would embed it into the html code with <img src="http://countersite.i2p/cgi-bin/counter.cgi?site=324832483">
Note the random number. There would be no need for me to even know what site it's counting for.
And, that would all you would have to do on your end. That is if you just want a count. If you want graphs and more complex breakdowns, that's another story.
But, a simple one would be easy. And, as for privacy, so long as you trust the person who's counter you are using, then you are good.
Feel free to hit me up on IRC if you want to discuss this further.
As for discussion, this is a good place to do it.