Export chart image data locally - Javascript highcharts

Javascript examples for highcharts:Chart Data

Description

Export chart image data locally

Demo Code

ResultView the demo in separate window

<html>
   <head> 
      <title>Highcharts Demo</title> 
      <meta name="viewport" content="width=device-width, initial-scale=1"> 
      <script type="text/javascript" src="https://code.jquery.com/jquery-git.js"></script> 
   </head> 
   <body> 
      <script src="https://code.highcharts.com/highcharts.js"></script> 
      <script src="https://code.highcharts.com/modules/exporting.js"></script> 
      <script src="https://code.highcharts.com/modules/offline-exporting.js"></script> 
      <div id="container"></div> 
      <button id="export">Export chart locally</button> 
      <script type="text/javascript">
var chart = Highcharts.chart('container', {
  exporting: {//from w  ww  . j a  va2 s . c o m
    fallbackToExportServer: false
  },
  series: [{
    data: [71.5, 106.4, 129.2, 176.0, 135.6, 148.5, 216.4, 194.1, 54.4]
  }]
});
$('#export').click(function() {
  chart.exportChartLocal();
});

      </script>  
   </body>
</html>

Related Tutorials