我可以将转换后的image.svg用作谷歌地图图标.我正在将我的png图像转换为svg,我想使用这个像可以旋转的谷歌地图符号.我已经尝试使用谷歌地图符号但我希望有一个像汽车,男人等图标...这就是为什么我将我的一些png文件转换为svg,就像这个示例网站他用于这些http:/ /www.goprotravelling.com/
我有一个XML,它通过XSLT转换为HTML.XML能够包含JavaScript,并且它可以正确地将其转换为HTML,就像我在许多其他页面中一样.它只是不适用于GoogleMaps,我怀疑,我的JavaScript在某处出错了.
生成的HTML的相关部分看起来如下所示.
HTML /脚本中发生了什么:
<body
onload="start();">.google.maps.对我来说,这看起来像以下是错误的某个地方.
var map_options = {
center: new google.maps.LatLng(44.54, -78.54),
zoom: 8,
mapTypeId: google.maps.MapTypeId.ROADMAP
}
Run Code Online (Sandbox Code Playgroud)
但几个小时后,我仍然无法弄清楚它是什么.
<html>
<head>
...
<script src="http://maps.googleapis.com/maps/api/js?sensor=false" type="text/javascript">
</script>
<script type="text/javascript">
function start()
{
var map_canvas = document.getElementById('map_canvas');
// If the element can be located, we make it green. Checked.
// If we give the function another name than start, it won't be …Run Code Online (Sandbox Code Playgroud)