Ability to see the IP/Domain name of visitors

Hi,

It would be very useful to have an option that would save the IP addresses (or domain names) of all the visits. This would definitely make me switch from Google Analytics, whose privacy policy does not allow the disclosure of such information.

EDIT

[b]The following SQL statement did the trick for me:


SELECT inet_ntoa(conv(hex(location_ip), 16, 10)) AS IP FROM piwik_log_visit

[/b]

IP addresses are saved.

SELECT p.location_ip FROM piwik_log_visit p;

Hi,
I used the query suggested by Robocoder and it displays results such as:
168102741
168103197
-1407668477
2130706433

Are these crypted? how can i extract a readable and understanable ip address, something like 10.24.155.3 or 172.24.89.56??
and how come they are stored as negatives??

Is there any api/function to convert such ip addresses into readable ones??

Thanks in advance,
Chhaya

The IP addresses are stored in network format – there’s no encryption.

If you see negative numbers, it’s because the MSB is set, e.g., an IP address >= 128.0.0.0.

Try inet_ntoa(). If that doesn’t work, it’s fairly trivial to craft your own long2ip() function.

I agree, i think it would be very useful and beneficial to be able to see the IP address of my visitors. Preferably right next to their hostname within piwik. To be honest i’d rather have an IP adddress rather than a link to some joe shmo commercial internet provider web page.
It’s also the only reason i use clicky and statcounter over piwik.
Just my 2 cents tho…

Am i the only one here that finds IP Addresses crucial to statistics reporting?

[quote=Stuntfoto @ Feb 20 2009, 02:10 AM]I agree, i think it would be very useful and beneficial to be able to see the IP address of my visitors. Preferably right next to their hostname within piwik. To be honest i’d rather have an IP adddress rather than a link to some joe shmo commercial internet provider web page.
It’s also the only reason i use clicky and statcounter over piwik.
Just my 2 cents tho…

Am i the only one here that finds IP Addresses crucial to statistics reporting?[/quote]

Hei Stuntfoto,

I also think the tracking of the IP address should be part as default of any web statistics soft. I hope Piwik will evolve in that direction even if it doesn’t seem to be in their policy at the moment.
Anyway could you explain/show us how did you manage to combine Piwik, clicky and statcounter?? I would like to to the same on my website style_emoticons/<#EMO_DIR#>/rolleyes.gif

Thanks in advance, style_emoticons/<#EMO_DIR#>/rolleyes.gif
Patoche

same for me : I would really like to have a plugin for IP statistics style_emoticons/<#EMO_DIR#>/rolleyes.gif

I’m not a plug-in-level coder, but I had the same concern and found the mysql function INET_NTOA() to serve this purpose well.

SELECT INET_NTOA(location_ip) AS IP FROM log_visit

Below is the query I’m building for the custom report I plan to build.
I guess it’s not completely tested yet, but this might be a good starting point for anyone on this thread.

SELECT COUNT(DISTINCT a.name) AS pageviews, l.visit_server_date AS svr_date, l.visit_total_actions AS actions, l.visit_total_time AS tot_time, l.referer_name, l.referer_keyword AS keyword, l.location_country AS country, CASE WHEN l.location_provider = 'Ip' THEN 'Unknown' ELSE l.location_provider END AS isp FROM log_action a INNER JOIN log_link_visit_action v ON a.idaction = v.idaction INNER JOIN log_visit l ON l.idvisit = v.idvisit WHERE l.visit_server_date BETWEEN '2009-04-01' AND '2009-04-20' GROUP BY l.visit_server_date, l.visit_total_actions, l.visit_total_time, l.referer_name, l.referer_keyword, INET_NTOA(l.location_ip), l.location_country, l.location_provider ORDER BY l.visit_server_date, l.visit_first_action_time ;

I’m new to piwik and to this forum. I apologize if this is an inappropriate post or contains errors.

hallo
any news about this feature?
will it be implemented or there is a plugin doing this?
i’ve looked Live module but it doesn’t give ip address

[quote=smccain @ Apr 16 2009, 09:11 PM]I’m not a plug-in-level coder, but I had the same concern and found the mysql function INET_NTOA() to serve this purpose well.

SELECT INET_NTOA(location_ip) AS IP FROM log_visit

Below is the query I’m building for the custom report I plan to build.
I guess it’s not completely tested yet, but this might be a good starting point for anyone on this thread.

SELECT COUNT(DISTINCT a.name) AS pageviews, l.visit_server_date AS svr_date, l.visit_total_actions AS actions, l.visit_total_time AS tot_time, l.referer_name, l.referer_keyword AS keyword, l.location_country AS country, CASE WHEN l.location_provider = 'Ip' THEN 'Unknown' ELSE l.location_provider END AS isp FROM log_action a INNER JOIN log_link_visit_action v ON a.idaction = v.idaction INNER JOIN log_visit l ON l.idvisit = v.idvisit WHERE l.visit_server_date BETWEEN '2009-04-01' AND '2009-04-20' GROUP BY l.visit_server_date, l.visit_total_actions, l.visit_total_time, l.referer_name, l.referer_keyword, INET_NTOA(l.location_ip), l.location_country, l.location_provider ORDER BY l.visit_server_date, l.visit_first_action_time ;

I’m new to piwik and to this forum. I apologize if this is an inappropriate post or contains errors.[/quote]

Good info. Thank you!

I agree : this feature would be really useful for me too, to be able to have IP and date of visit of visitors…

thanks !

Thanks piwik developers for such product.

If you needn`t IP just disable this option.

P.S.: for me ip is not important too. style_emoticons/<#EMO_DIR#>/wink.gif

Side note: as of Piwik 0.4, location_ip is stored as a non-negative number.

hi all actually i found out a way to get the ips out already.

<?php $hex = hexdec('af9c7822'); //eg From DB175.156.120.34 $ip = long2ip($hex); // This will be your actual ip address ?>

Ah thanks.

The following SQL statement did the trick for me:

SELECT inet_ntoa(conv(hex(location_ip), 16, 10)) AS IP FROM piwik_log_visit

Nice ! That works just fine for me too !

Actually every time when you visit website your IP address as visitor has been saved into logs. Owner of the website or anybody else who have access to logs can see your IP address.Visit http://www.ip-details.com/ to trace ip-address.