开发者

Can't view embedded Google Maps because "Internet Explorer has modified this page to help prevent cross-site scripting"

The offending page is http://beta.westlake.school.nz开发者_StackOverflow中文版/school-details if viewed using IE8


In my case, this seemed to be caused by a couple of single quotes in the hnear argument in the Google URL. Removing the quotes in both the iframe src and the a href attributes fixed the problem.

For example,

<a href="http://maps.google.com/maps/ms?source=embed&amp;hl=fr&amp;geocode=&amp;aq=&amp;ie=UTF8&amp;hq=&amp;hnear=Ch%C3%A2teau-d'%C5%92x,+Riviera-Pays-d'Enhaut,+Vaud,+Switzerland&amp;msa=0&amp;ll=46.472921,7.130213&amp;spn=0.021578,0.055747&amp;msid=208989902893156915814.0004a534bae54848e2335">

became

<a href="http://maps.google.com/maps/ms?source=embed&amp;hl=fr&amp;geocode=&amp;aq=&amp;ie=UTF8&amp;hq=&amp;hnear=Ch%C3%A2teau-d%C5%92x,+Riviera-Pays-dEnhaut,+Vaud,+Switzerland&amp;msa=0&amp;ll=46.472921,7.130213&amp;spn=0.021578,0.055747&amp;msid=208989902893156915814.0004a534bae54848e2335">

Not sure whether that's because Google didn't need the argument in my case, or whether it could handle the modification gracefully.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜