How to show user country by IP (II post)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,
I send this message for the second time becouse I had problems with the
mailing list.


I would like to show the country of the user provider (only by organizations
databases).
I haven't problem with provider located in europe, simply this code:

$indirizzo_cliente = $_SERVER["REMOTE_ADDR"];
$fp = file
("http://www.ripe.net/whois?form_type=simple&full_query_string=&searchtext=$
indirizzo_cliente");

while (list ($line_num, $line) = each ($fp)) {
     if(strstr($line,"country")!=""){ // or other fields like person,
address etc etc
          $lineaok[$i]=$line;
     }
}

THE PROBLEM cames when a want to show the country of providers located in
NORTH AMERICA,
in this case I have to send the query by POST METHOD (ARIN DATABASE).
So I can't match both the results of the two interrogation  in the same php
page, get  and  post method in the same php script.

Please don't suggest method based on commercial services, a would like to
find a programming based solution.


Sebastiano

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux