Fix location collection for frontpage map
authorLaury GvR <laury@gaslightmedia.com>
Tue, 21 Aug 2018 20:27:07 +0000 (16:27 -0400)
committerLaury GvR <laury@gaslightmedia.com>
Tue, 21 Aug 2018 20:27:07 +0000 (16:27 -0400)
parts/map-section.php

index 9209bc1..ddf9f76 100644 (file)
         $locations = array();
         foreach($pages as $page){
             $args = array(
-                'id'          => $page,
+                'post_id'     => $page,
                 'post_type'   => 'page',
                 'post_status' => 'publish',
                 'numberposts' => 1
             );
             $location_page = get_posts($args);
+            console.log($location_page);
             // echo '<pre>', print_r($location_page), '</pre>';
             if( !empty($location_page) ){
                 $content = get_excerpt_by_id($location_page[0]->ID, 20);