Example #1
2
 /**
  * Outputs the chart javascript into the page
  *
  * Pass in a string of the html elementID that you want the chart to be
  * rendered into. Plus, if the dataTable function was never called on the
  * chart to assign a DataTable to use, it will automatically attempt to use
  * a DataTable with the same label as the chart.
  *
  * @param string $elementID
  * @return string Javscript code blocks
  */
 public function outputInto($elementID = NULL)
 {
     if ($this->dataTable === NULL) {
         $this->dataTable = $this->chartLabel;
     }
     if (gettype($elementID) == 'string' && $elementID != NULL) {
         $this->elementID = $elementID;
     }
     return Lavacharts::_build_script_block($this);
 }