谷歌地图API标签不验证 [英] Google maps api javascript tag not validating

查看:102
本文介绍了谷歌地图API标签不验证的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

看看获取当前网站的网站是否正在使用W3C进行完全HTML5验证



这是Google地图API JavaScript标记,它无法验证。

 < script src =http://maps.googleapis.com/maps/api/js?libraries=places&sensor=false >< /脚本> 

这是W3C的回应


&没有开始一个字符引用。 (&可能应该已被转义为&)。

它不喜欢& 定义传感器是真还是假。



我已经尝试了以下内容:

 < script src =http://maps.googleapis.com/maps/api/js?libraries=places&ampsensor=false>< / script> 

运行页面时,我从API中获得一个错误,说明我没有使用& sensor和它需要设置为真或假。



任何人有任何想法如何克服这个请。



谢谢我认为你只是忘记把分号放在& amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp; amp ;, amp;

 < script src =http://maps.googleapis.com/maps/api ?/ JS库=地方&放大器;放大器;传感器=假>< /脚本> 

应该可以工作


Looking at getting a current website site am working on fully HTML5 validated using W3C

This is the Google map API Javascript tag that is failing to validate.

<script src="http://maps.googleapis.com/maps/api/js?libraries=places&sensor=false"></script>

This is the response from W3C

& did not start a character reference. (& probably should have been escaped as &.)

It does not like the & when defining if the sensor is true or false.

I have tried the following

<script src="http://maps.googleapis.com/maps/api/js?libraries=places&ampsensor=false"></script>

When running the page i get a Error from the API explaining i have not used &sensor and it needs to be set to true or false.

Anyone have any ideas how to overcome this please.

Thanks in advance.

解决方案

I think you just have forgotten to put a semicolon behind the &amp;

<script src="http://maps.googleapis.com/maps/api/js?libraries=places&amp;sensor=false"></script>

should work

这篇关于谷歌地图API标签不验证的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆