Geo_Map::GetMapSearchCenter PHP Method

GetMapSearchCenter() public static method

Gives the body map-centering (js call) part for the map front end search by map-based rectangle selection
public static GetMapSearchCenter ( ) : string
return string
    public static function GetMapSearchCenter()
    {
        global $Campsite;
        $tag_string = '';
        $map_suffix = '_search';
        $tag_string .= 'geo_object' . $map_suffix . '.map_showview();';
        return $tag_string;
    }

Usage Example

Ejemplo n.º 1
0
<?php 
$bbox_divs = array('tl_lon' => 'top_left_longitude', 'tl_lat' => 'top_left_latitude', 'br_lon' => 'bottom_right_longitude', 'br_lat' => 'bottom_right_latitude');
$map_width = 600;
$map_height = 400;
echo Geo_Map::GetMapSearchHeader($map_width, $map_height, $bbox_divs);
?>

</head>
<body onLoad="return false;">
<div class="map_preview_serach">
<div class="map_mappart_outer_serach">
<div class="map_mappart_serach">
<div class="map_mapmenu_serach">
<a href="#" onClick="<?php 
echo Geo_Map::GetMapSearchCenter();
?>
 return false;"><?php 
putGS('show initial map view');
?>
</a>
</div><!-- end of map_mapmenu -->
<?php 
echo Geo_Map::GetMapSearchBody();
?>
</div><!-- end of map_mappart -->
</div><!-- end of map_mappart_outer -->
</div><!-- end of map_preview -->
<div class="map_search_rectangle">
<ol>Top left
<li>longitude: <span id="top_left_longitude"> </span></li>
All Usage Examples Of Geo_Map::GetMapSearchCenter