Location items map
-
Hello World!
I like this plugin, but I’m a little confused.
I have 3 custom post types – locations, hotels and museums.
So museums and hotels posts have some field called “museums_location_name” and “hotels_location_name”I would like to add map to sidebar of location to display this location and all museums and hotels in this location.
So i can display them, but not at once
<?php query_posts( array (‘post_type’ => ‘hotel’, ‘meta_key’ => ‘hotels_location_id’, ‘meta_value’ => $location_id) ); ?>
<?php echo GeoMashup::map( ‘map_content=contextual’ ); ?>
<?php wp_reset_query(); ?>
^^this works<?php query_posts( array (‘post_type’ => ‘museum’, ‘meta_key’ => ‘museums_location_id’, ‘meta_value’ => $location_id) ); ?>
<?php echo GeoMashup::map( ‘map_content=contextual’ ); ?>
<?php wp_reset_query(); ?>
^^this works 2<?php query_posts( array (‘post_type’ => ‘hotel,museum’, ‘meta_key’ => ‘hotel_location_id,museums_location_id’, ‘meta_value’ => $location_id) ); ?>
<?php echo GeoMashup::map( ‘map_content=contextual’ ); ?>
<?php wp_reset_query(); ?>
^^and this doesn’t workWhat wrong with my code?
- The topic ‘Location items map’ is closed to new replies.