
Originally Posted by
Mr.Bill
Where did you put the geoip.inc is the location set right in the script?
I added it to the map from ProxLists.com (as it is addon domain) and yes, every location is done correctly..
Though, can someone check this code?
PHP Code:
<body>
<?php
/*
MOD VISITORS COUNTRY FLAGS
START INSERT
*/
if (!class_exists("GeoIP"))
{
include(ROOT_PATH."geoip.inc");
}
$gi = geoip_open(ROOT_PATH."GeoIP.dat",GEOIP_STANDARD);
$countries = array();
/*
MOD VISITORS COUNTRY FLAGS
END INSERT
*/
?>
<div id="outer">
<div id="inner">
<div id="header">
<h1>Prox<span>Lists</span>.Com</h1>
<h2>Dedicated to students!</h2>
</div>
<a href="http://proxlists.com/advertise.php"><div id="splash"></div></a>
<div id="menu">
<ul>
<li class="first"><a href="http://proxlists.com">Home</a></li>
<li><a href="exchange.php">Submit Proxy</a></li>
<li><a href="advertise.php">Advertise</a></li>
<li><a href="popular.php">Most Popular</a></li>
<li><a href="contact.php">Contact</a></li>
</ul>
</div>
<div id="primarycontent">
<!-- primary content start -->
<div class="post">
<div class="header">
<h3><center><?php echo date("F d, Y"); ?> - Visitors Online</center></h3></div>
<div class="content">
<p>Blablabla<br />
<?php $cid = geoip_country_code_by_addr($gi, $row['session_ip']);
if (empty($cid)) $cid = "lan";
$countries[$cid] = isset($countries[$cid]) ? $countries[$cid]+1 : 1;
$username = "<img src=\"".ROOT_PATH."flags/".strtolower($cid).".gif"."\" alt=\"".(($cid != "lan") ? $gi->GEOIP_COUNTRY_NAMES[$gi->GEOIP_COUNTRY_CODE_TO_NUMBER[$cid]] : "Unknown or LAN")."\" border=0> ".$username;
?>
<?php
$cid = geoip_country_code_by_addr($gi, $row['session_ip']);
if (empty($cid)) $cid = "lan";
$countries[$cid] = isset($countries[$cid]) ? $countries[$cid]+1 : 1;
$invitado_online_list = "<font color=\"#00FFFF\">".$num_guests_online."</font><img src=\"".ROOT_PATH."flags/".strtolower($cid).".gif"."\" alt=\"".(($cid != "lan") ? $gi->GEOIP_COUNTRY_NAMES[$gi->GEOIP_COUNTRY_CODE_TO_NUMBER[$cid]] : "Unknown or LAN")."\" border=0> ".$invitado_online_list ;
if ($num_guests_online > 1){
$invitado_online_list .= " , ";
}
?>
{invitado_online_list}
</p></div></div>
Please don't talk about the wrong code to center text etc.. just watch the GeoIP code for flags 
Greetz & thanks
Bookmarks