hi!
is it possible to use a relative URL to load the kml?
ie,
get_bloginfo('template_directory').'/maps/'.get_post_meta($post->ID, 'Mapfile', true);
instead of say,
'http://site.com/wp-content/themes/mytemplate/maps/map1.kml'
Thanks :)
hi!
is it possible to use a relative URL to load the kml?
ie,
get_bloginfo('template_directory').'/maps/'.get_post_meta($post->ID, 'Mapfile', true);
instead of say,
'http://site.com/wp-content/themes/mytemplate/maps/map1.kml'
Thanks :)
G'day, if you're adding the map in code through a template, then yes you can, e.g.
$kml = get_bloginfo('template_directory').'/maps/'.get_post_meta($post->ID, 'Mapfile', true);
flexmap_show_map(array(
'src' => $kml,
'width' => 500,
'height' => 400,
));
If you're using the shortcode, then you'll need to filter 'flexmap_shortcode_attrs' to set the 'src' attribute that way.
You must log in to post.