title: How can I fix Highcharts error #13?
body: <p>I use highchart so, the user can close and open the chart page and redraw the chart, in some case give me this error, how can I fix it, Thanks
  Here is my code</p>
  
  <pre><code> function populateGraph(graph1data1,graph1data2,id,time,bottomText,tickinterval){
  $(function () {
    $('#'+id).highcharts({
        chart: {
            type: 'line'
        },
        xAxis: {
          tickWidth: 0,
          categories: ['1,2,3,4']
        },
        yAxis: {
          gridLineColor: '#fff',
            title: {
                text: ''
            },
            labels: {
                formatter: function() {
                    return '';
                }
            }              
        },
        navigation: {
          buttonOptions: {
              enabled: false
          }
      },
        series: [{
            name: 'This ',
            data: [1,2,3,4],
            color: '#1e71ef'     
        }, {
            name: 'Last ',
            data: [5,6,7,8],
            color:'#dfe0e1'
        }]
    });
  });
  }
  }
  
  
  
  
         function loadOnlineDashboardChannel(channel){
            $.ajax({
            type: "get",
            dataType: 'html',
            data: {},
            url: "/companies/2/online_dashboard_channel",
            success: function(data, status){ 
            var obj = JSON.parse(data);
            var template_data = { 
              measures_list:   
                obj.measures         
            };
            $(function() { 
          var tmplHTML_measures = '{{#measures_list}} &lt;div class="col-lg-11  col-lg-offset-1"&gt;&lt;p class="indicator-title gray-bottom-border"&gt;{{name}}&lt;/br&gt;&lt;/p&gt;&lt;div&gt;&lt;p&gt;&lt;span class="font30px"&gt;{{total}} &lt;/span&gt; Total {{name}}&lt;br&gt;&lt;span class="green-text"&gt;{{increase}}%&lt;/span&gt; from last &lt;span class="metric_time"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;div class="graph-header"&gt;&lt;h3&gt;{{this_interval}} &lt;/h3&gt;&lt;p&gt;New {{name}}&lt;/p&gt;&lt;p class="percentage-graph green-text"&gt;{{percentag e}}%&lt;p&gt;&lt;/div&gt;&lt;div id={{graph_id}} class="graph"&gt;&lt;/div&gt; &lt;/div&gt;{{/measures_list}}';   
            Handlebars.render = function(tmpl, data){data = data || {};return                                                       Handlebars.compile(tmpl)(data);};  
        $("#template").empty().append(Handlebars.render(tmplHTML_measures,template_data) );
        var data_graph;
        for ( var i = 0; i &lt; obj.measures.length; i++ ) {
          data_graph=obj.measures[i];
                        populateGraph(data_graph.this_interval_detail,data_graph.last_interval_detail,data_graph.graph_id,time,obj.bottom_graph_text,parseInt($('#timeframe-select').find(":selected").attr('interval')) );
        }              
       })
  
  
    },
    error: function(error) {
  
  }
  });
  
  return this;
  };
  </code></pre>
  
  <p>I use handlebar so in this part 
                
  in
                 var tmplHTML_measures
  I create the div, in the for I call the function to draw the chart.</p>
  
  <p>Thanks, I repeat sometimes it works perfectly and sometimes fail give me the error #13</p>