Embedding Google Visualizations

  • Author
  • #612949

    I am aware that it’s possible to include Google’s Visualizations in a post by publishing the chart/gadget in Google Docs (http://en.support.wordpress.com/google-docs/), but I’m not sure how to control the size of these charts etc. once included in a post.

    Here (http://dl.dropbox.com/u/1058849/test_weight.html) I’ve got three simple Google linecharts that connect to dummy data in a Google Spreadsheet. Is it possible for me to present these charts similarly in a post/page/sidebar? I would prefer not to use a static image, as the data will be updated regularly, and I like having the tooltips. Alternatively, are there any similar visualization options for which wordpress.com shortcodes exist?

    Thanks all

    (Also, where would I find a markup reference for these forums?)


    If you could paste the code here in the forums between code tags, we can take a look at it. There should be height and width declarations on the iframe code that can be used to adjust the size. When adjusting the size though you always have to keep in mind the width of the post or page you are inserting it into. In some instances, if your theme has the option, it might be best to insert it into a page with no sidebar so you can have it wider. It will of course all depend on the nature of the embed and where you want to put it and the options your chosen theme offers.


    Put the code like this:

    <code>iframe code here</code>


    Thanks for your reply.

    I’m afraid I wasn’t very clear in my original post. I’m able to adjust the iframe’s height and width, but I’m not sure whether it’s possible to adjust the height and width of the gadget itself.

    <iframe width='400' height='200' frameborder='0' src='https://spreadsheets.google.com/spreadsheet/pub?hl=en&hl=en&key=0ArAr-QBaLf6ndGlRaWhaaXc4bk5ZUEdNX2o1YW9JTkE&single=true&gid=8&output=html&widget=true'></iframe>

    Thanks again.


    I think the chart/gadget would have to be sized or resized in the google doc. The only thing we could do here would be to adjust the size of the iframe.


    Thanks again. That’s what I suspected, but it’s good to have your confirmation. I haven’t been able to find any way to alter the chart’s size in Google Docs, but will chase that up elsewhere and report back if I find an answer.



    Yeah, I can’t help on Gdocs. I’ve never even looked at them or played with them.

The topic ‘Embedding Google Visualizations’ is closed to new replies.