Docs updated:
https://developers.google.com/chart/interactive/docs/printing

Jon


On Mon, Feb 24, 2014 at 4:17 PM, asgallant <[email protected]>wrote:

> Sorry, typo in the code, it should be:
>
> var chart = new google.visualization.GeoChart(document.getElementById('
> chart_div'));
> google.visualization.events.addListener(chart, 'ready', function () {
>     chart_div.innerHTML = '<img src="' + chart.getImageURI() + '">';
> });
> chart.draw(data, options);
>
> On Monday, February 24, 2014 4:17:18 PM UTC-5, asgallant wrote:
>>
>> Try putting that inside a "ready" event handler for the GeoChart:
>>
>> var chart = new google.visualization.GeoChart(document.getElementById('
>> chart_div'));
>> google.visualization.events.addListener(geochart, 'ready', function () {
>>     chart_div.innerHTML = '<img src="' + chart.getImageURI() + '">';
>> });
>> chart.draw(data, options);
>>
>>
>> On Monday, February 24, 2014 3:36:34 PM UTC-5, mani vannan wrote:
>>>
>>>  <html>
>>> <head>
>>> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
>>> <title>Insert title here</title>
>>> <script type="text/javascript" src="https://www.google.com/jsapi";></script>
>>>
>>>   <script type="text/javascript">
>>>   google.load('visualization', '1', {'packages': ['geochart']});
>>>   google.setOnLoadCallback(drawMarkersMap);
>>>
>>>    function drawMarkersMap() {
>>>    var data = google.visualization.arrayToDataTable([
>>>      ['City',   'Population', 'Area'],
>>>      ['Rome',      2761477,    1285.31],
>>>      ['Milan',     1324110,    181.76],
>>>      ['Naples',    959574,     117.27],
>>>      ['Turin',     907563,     130.17],
>>>      ['Palermo',   655875,     158.9],
>>>      ['Genoa',     607906,     243.60],
>>>      ['Bologna',   380181,     140.7],
>>>      ['Florence',  371282,     102.41],
>>>      ['Fiumicino', 67370,      213.44],
>>>      ['Anzio',     52192,      43.43],
>>>      ['Ciampino',  38262,      11]
>>>    ]);
>>>
>>>    var options = {
>>>      region: 'IT',
>>>      displayMode: 'markers',
>>>      colorAxis: {colors: ['green', 'blue']}
>>>    };
>>>
>>>    var chart = new 
>>> google.visualization.GeoChart(document.getElementById('chart_div'));
>>>    chart.draw(data, options);
>>>
>>>   chart_div.innerHTML = '<img src="' + chart.getImageURI() + '">';
>>>
>>> };
>>>
>>>       </script>
>>> </head>
>>> <body>
>>> <div id="chart_div" style="width: 900px; height: 500px;"></div>
>>>
>>>
>>> </form>
>>> </body>
>>> </html>
>>>
>>>   --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to
> [email protected].
> Visit this group at
> http://groups.google.com/group/google-visualization-api.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to