Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include("geoip.inc"); //library
- $gi = geoip_open("GeoIP.dat", GEOIP_STANDARD); //open database
- //fetch image
- <img src="images/country_flags/_' . strtolower(geoip_country_code_by_addr($gi, $ip)) . '.png" title="Server located in ' . geoip_country_name_by_addr($gi, $ip) . '" />
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement