How to embed a Google Trends chart into a website (doesn't work)?
-
Hello.
I'm trying from the service Google Trends to insert data into the site generated by the service itself but it doesn't work.
The service generates the following code:
<script type="text/javascript" src="https://ssl.gstatic.com/trends_nrtr/2213_RC01/embed_loader.js"></script> <script type="text/javascript"> trends.embed.renderExploreWidget("TIMESERIES", {"comparisonItem":[{"keyword":"obama","geo":"RU","time":"today 12-m"}],"category":0,"property":""}, {"exploreQuery":"geo=RU&q=obama&date=today 12-m","guestPath":"https://trends.google.ru:443/trends/embed/"}); </script>
I put it on the site, but in response I see this:
I tried to paste the code on the codepen - the same does not work there, but with a different output.
Help understand the situation.JavaScript Anonymous, Feb 16, 2019 -
The problem is not in the code - for some reason, your site is not available personally.
Nora Hess
1 Answers
Your Answer
To place the code, please use CodePen or similar tool. Thanks you!