100+
May 16, 2013
February 15, 2013
Nearby Map allow you to easily insert a Map into your content. With it, you can show a main location and every interesting places around it.
The map is dynamic. You can show to users the best way to travel from your main location to any other one.
Nearby Map also includes SEO optimisation with Schema.org markup.
Here’s a few example to show you what you can do with Nearby Map
Nearby Map does not use Google Map, beacause there is other good librairies :
When a map is displayed, structured data from schema.org is included for each location.
Nearby Map has been created with custom hooks and filter : you can override every data and action to improve or adapt the plugin to suit your needs. FAQ
/wp-content/plugins/ directory[maps] into your content area, or use <?php echo nbm_render_map(); ?> into one template file to render the map[place] into your place content area, or use <?php echo nbm_place_information(); ?> into your single place (or specified CPT) template file to show information about current placeUsing nbm_post_type. You just have to modify then paste this following code into your functions.php theme file.
Tired of the same old maps? CloudMade give ability for users to use custom map or build thier own.
After choosing, you juste have to precise the id of your custom style into your functions.php, by the way of the filter cloudmade_style.
<?php add_filter( 'cloudmade_style', 'my_custom_style' );
function my_custom_style(){
//If I want to use "midnight Comander coloration" style
return 999;
} ?>
Loading time tiles is still faster if you opt for a custom style proposed by CloudMade (8 possibilities).
You can see some examples at screenshots section.
Yes, there are other tile provider than CloudMade (used by default in this plugin). To chose for another, simply paste this function into your functions.php.
<?php add_filter( 'maps_datas', 'function_for_alter' );
function function_for_alter( $maps_datas ){
$maps_datas['tiles'] = "http://{s}.mqcdn.com/tiles/1.0.0/map/{z}/{x}/{y}.jpg";
$maps_datas['attribution'] = "attribution I want/use to show";
$maps_datas['subdomains'] = array('otile1','otile2','otile3','otile4');
return $maps_datas;
} ?>
I tested some tiles providers, and I confirm they work with Nearby Map :
You can also modify many other options using maps_datas filter
Yes, doing this into your functions.php theme file.
places_args filter
Use the filter namned nbm_try_to_find_with_openstreetmap. Just paste this :
You can use yours, using cloudmade_key filter hook, into your functions.php
You can return false on nbm_need_more filter hook :
You can return false on nbm_need_route filter hook :
Just return false on nbm_places_link filter hook :
It’s easy to rewrite all the query with markers_querys.
‘type_of_place’,
‘field’ => ‘id’,
‘term’ => 56
)
);
return $m;
} ?>
There is nbm_map for that…
Use nbm_place_information filter…