Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
julles committed Mar 22, 2016
1 parent 3fff5b7 commit d926e2c
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions src/Highcharts.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,21 +88,27 @@ public function display($id = "" , $array = [] , $options = ['jquery.js' => true
$("#'.$id.'").highcharts('.$array.');
var chart = $("#'.$id.'").highcharts(),
svg = chart.getSVG();
format = "'.$options['format'].'";
if(format == "svg")
{
var chart = $("#'.$id.'").highcharts(),
svg = chart.getSVG();
$("#'.$id.'").text(svg);
}
$("#'.$id.'").text(svg);
}else if(format == "base64"){
base = "data:image/svg+xml;base64," + btoa(svg);
$("#'.$id.'").text(base);
}
});
</script>
<div id="'.$id.'" style="width:100%; height:400px;"></div>
';
';
return $view;
}

Expand Down

0 comments on commit d926e2c

Please sign in to comment.