init_user_map ( $m['mapID'] , $m['mapStyle'] , $m['latitude'] , $m['longitude'] , $m['icon_large_owner'] , $m['icon_small_owner'] , $m['textOwner'] , $m['textVisitor'] , $m['icon_large_visitor'] , $m['icon_small_visitor'] ); $new_coords = mysql_query ( "SELECT * FROM ".TBL_VISITORS." vis, ".TBL_REGIONS." reg WHERE vis.regionID = reg.regionID && vis.mapID='$m[mapID]' && vis.date > '$m[updateStamp]'" ); if ( mysql_num_rows ( $new_coords ) > 0 ){ $draw -> prep_draw(); while ( $o = mysql_fetch_array ( $new_coords ) ){ $draw -> plot ( $o['latitude'] , $o['longitude'] , $m['icon_large_visitor'] , $m['icon_small_visitor'] ); } $draw -> plot ( $m['latitude'] , $m['longitude'] , $m['icon_large_owner'] , $m['icon_small_owner'] ); $total = mysql_fetch_array ( mysql_query ( "SELECT sum(count) as total_count FROM ".TBL_VISITORS." WHERE mapID='$m[mapID]'" ) ); $draw -> add_count ($total['total_count'],$m['mapStyle']); $draw -> finish_draw(); } mysql_query ( "UPDATE ".TBL_MAPS." SET updateStamp='".time()."' WHERE mapID='$m[mapID]'" ); } include "_dinit.php"; ?>