| 1 |
<?php |
| 2 |
/** |
| 3 |
* GPX Shortcode |
| 4 |
* |
| 5 |
* Use with [leaflet-gpx src="..."] |
| 6 |
* |
| 7 |
* @param array $atts user-input array |
| 8 |
* @return string JavaScript |
| 9 |
*/ |
| 10 |
|
| 11 |
// Exit if accessed directly |
| 12 |
if ( !defined( 'ABSPATH' ) ) exit; |
| 13 |
|
| 14 |
include_once(LEAFLET_MAP__PLUGIN_DIR . 'shortcodes/class.geojson-shortcode.php'); |
| 15 |
|
| 16 |
class Leaflet_Gpx_Shortcode extends Leaflet_Geojson_Shortcode { |
| 17 |
/** |
| 18 |
* @var string $type how leaflet renders the src |
| 19 |
*/ |
| 20 |
public static $type = 'gpx'; |
| 21 |
} |