我正在将谷歌趋势嵌入到HTML页面中,并希望传递包括ö,ä和ü等变音符号在内的短语。
但该图表总是空白。
我为这些字符尝试了不同的编码,例如:(例如ö)
H%25C3%25B6rfigur
或
H%C3%B6rfigur
或
H%F6rfigur
我试过这段代码:
<script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/925_RC01/embed_loader.js"></script>
<script type="text/javascript">
trends.embed.renderExploreWidget("TIMESERIES", {"comparisonItem":[{"keyword":"H%25C3%25B6rfigur","geo":"AT","time":"today 5-y"}],"category":0,"property":""}, {"exploreQuery":"geo=AT-4&q=sheep","guestPath":"https://trends.google.at:443/trends/embed/"});
</script>
请帮助我,我现在正在为此工作!
答案 0 :(得分:1)
您是否尝试过google.com/trends/explore并从嵌入对话框中复制?
e.g。对于https://trends.google.com/trends/explore?q=%C3%BCber,我得到以下嵌入代码,工作正常:
<script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/1280_RC06/embed_loader.js"></script> <script type="text/javascript"> trends.embed.renderExploreWidget("TIMESERIES", {"comparisonItem":[{"keyword":"über","geo":"","time":"today 12-m"}],"category":0,"property":""}, {"exploreQuery":"q=%C3%BCber&date=today 12-m","guestPath":"https://trends.google.com:443/trends/embed/"}); </script>
您的查询是否可能没有足够的数据显示?