/** * Output JavaScript required for digest newest venue location map. Uses get_map_js(). * @since 2.1.0 * @version 2.1.0 * @param string $pin_icon URL of pushpin icon image file. * @return void */ function digest_venue_map_js($pin_icon = '') { global $hc_cfg; $pin_icon = $pin_icon == '' ? CalRoot . '/img/pins/pushpin.png' : $pin_icon; $result = doQuery("SELECT PkID, Lat, Lon FROM " . HC_TblPrefix . "locations WHERE IsActive = 1 AND Lat != '' AND Lon != '' ORDER BY LastMod DESC LIMIT 1"); if (hasRows($result)) { get_map_js(mysql_result($result, 0, 1), mysql_result($result, 0, 2), 1, $pin_icon, 1, CalRoot . '/index.php?com=location&lID=' . mysql_result($result, 0, 0)); } else { echo ' <style> #map_canvas_single {display:none;} </style>'; } }
<?php /** * @package Helios Calendar * @subpackage Default Mobile Theme */ if (!defined('isHC')) { exit(-1); } get_header(); get_map_js(map_venue_lat(), map_venue_lon(), 2, cal_url() . '/img/pins/default.png'); ?> </head> <body onload="map_init()"> <?php my_menu(2); ?> <nav class="sub"> <ul> <li> </li> <li><a href="javascript:;" id="me_link" onclick="map_near_me();">Near Me</a></li> <li><a href="javascript:;" id="list_link" onclick="map_list();">Show List</a></li> <li><a href="javascript:;" id="reset_link" onclick="map_reset();">Reset</a></li> </ul> </nav> <section> <div id="map_list" style="display:none;"></div> <div id="map_canvas"></div> </section>
document.getElementById(doLink).innerHTML = '<?php echo location_lang('Less'); ?> '; } else { document.getElementById(doTog).style.display = 'none'; document.getElementById(doLink).innerHTML = '<?php echo location_lang('More'); ?> '; } } //--> </script> <?php get_map_js($myLoc['Lat'], $myLoc['Lon'], 1, cal_url() . '/img/pins/pushpin.png', 1, $myLoc['Link_Directions']); ?> </head> <body onload="map_init()" id="top" class="bcsr-cal no-hero" itemscope itemtype="http://schema.org/WebPage"> <?php include 'head.php'; ?> <a name="top"></a> <div id="fb-root"></div> <script>(function(d, s, id) { var js, fjs = d.getElementsByTagName(s)[0]; if (d.getElementById(id)) return; js = d.createElement(s); js.id = id; js.src = "//connect.facebook.net/en_US/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs);
document.getElementById(doLink).innerHTML = '<?php echo event_lang('Less'); ?> '; } else { document.getElementById(doTog).style.display = 'none'; document.getElementById(doLink).innerHTML = '<?php echo event_lang('More'); ?> '; } } //--> </script> <?php get_map_js($myEvnt['Venue_Lat'], $myEvnt['Venue_Lon'], 1, cal_url() . '/img/pins/pushpin.png', 1, $myLnks['Venue_Directions']); ?> </head> <body onload="map_init()" itemscope itemtype="http://schema.org/WebPage"> <div id="fb-root"></div> <script>(function(d, s, id) { var js, fjs = d.getElementsByTagName(s)[0]; if (d.getElementById(id)) return; js = d.createElement(s); js.id = id; js.src = "//connect.facebook.net/en_US/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));</script> <header> <span>
/** * Output JavaScript required for current embedded map provider (configured within admin console settings). Activate map by adding call to map_init() in page onload event. Series unique wrapper for get_map_js() * @since 2.2.0 * @version 2.2.0 * @param resource $result MySQL result set (Requires: ID, Title, Date, Start Time, End Time & TBD, Description, Location ID, Location Name, Location Lat, Location Lon) * @return void */ function series_map($result) { global $hc_cfg; $venues = array(); $found = array(); mysql_data_seek($result, 0); while ($row = mysql_fetch_row($result)) { if (!in_array($row[7], $found)) { $venues[] = array($row[7], $row[8], $row[9], $row[10], "", "", "", "", "", "", "", "", "", ""); $found[] = $row[7]; } } get_map_js($venues[0][2], $venues[0][3], 3, cal_url() . '/img/pins/pushpin.png', 0, NULL, $venues); }