</div>
<div id="mapRegionData">
<?php $community_page_object = get_page( 155 ); ?>
- <?php $community_page_image = wp_get_attachment_url( get_post_thumbnail_id( 155 )); ?>
- <?php $community_page_content = json_encode(substr(strip_tags($community_page_object->post_content),0, 300)); ?>
+ <?php $community_page_image = wp_get_attachment_url( get_post_thumbnail_id( 155 )); ?>
+
+ <?php $community_page_content = substr(strip_tags($community_page_object->post_content),0, 300); ?>
+ <?php $community_page_content = json_encode(strip_shortcodes($community_page_content)); ?>
+
<a class="map-page-link" href="#"><div class="map-image-container"></div></a>
<div class="map-page-title-container"><a class="map-page-link map-title-link" href="#"><h4 class="map-page-title"></h4></a></div>
<div class="map-page-content"> </div>
$sites[$p->ID]['url'] = get_permalink($p->ID);
$sites[$p->ID]['title'] = get_the_title($p->ID);
$sites[$p->ID]['image'] = wp_get_attachment_url( get_post_thumbnail_id($p->ID));
- $sites[$p->ID]['content'] = substr(strip_tags($page_object->post_content),0, 300) . "...";
+// $sites[$p->ID]['content'] = substr(strip_tags($page_object->post_content),0, 300) . "...";
+ $filter_content = substr(strip_tags($page_object->post_content),0, 300) . "...";
+ $filter_content = strip_shortcodes($filter_content);
+ $sites[$p->ID]['content'] = $filter_content;
+
+
}
$js_sites = json_encode($sites);
//echo '<pre>', print_r($sites) , '</pre>';
// set the default data next to the dropdown community map
function set_default_data(){
regionData.find(".map-page-title").html('<?php echo $community_page_object->post_title; ?>');
- regionData.find(".map-image-container").css("height","200px").css("width", "300px").css("background", "url(' <?php echo $community_page_image; ?> ')no-repeat center center").css("background-position", "cover");
+ regionData.find(".map-image-container").css("height","175px").css("width", "300px").css("background", "url(' <?php echo $community_page_image; ?> ')no-repeat center center").css("background-position", "cover");
regionData.find(".map-page-content").html(default_content);
}
regionData.find(".map-page-link").attr("href", site_array[id]['url']);
regionData.find(".map-page-title").html(site_array[id]['title']);
- regionData.find(".map-image-container").css("height","200px").css("width", "300px").css("background", "url('" + site_array[id]['image'] + "')no-repeat center center").css("background-position", "cover");
+ regionData.find(".map-image-container").css("height","175px").css("width", "300px").css("background", "url('" + site_array[id]['image'] + "')no-repeat center center").css("background-position", "cover");
regionData.find(".map-page-content").html(site_array[id]['content']);
}, function () {