/**
  * Outputs the link to the Google JSAPI
  *
  * @access public
  * @since  2.3.0
  * @return string Google Chart API and lava.js script blocks
  */
 public function jsapi()
 {
     return $this->jsFactory->getCoreJs();
 }
예제 #2
0
 /**
  * Outputs the chart javascript into the page.
  *
  * Pass in a string of the html elementID that you want the chart to be
  * rendered into.
  *
  * @deprecated Use the Lavacharts master object to keep track of charts to render.
  * @codeCoverageIgnore
  * @access public
  * @since  2.0.0
  * @param  string $elemId The id of an HTML element to render the chart into.
  * @return string Javascript code blocks
  * @throws \Khill\Lavacharts\Exceptions\InvalidElementId
  *
  */
 public function render($elemId)
 {
     trigger_error("Rendering directly from charts is deprecated. Use the render method off your main Lavacharts object.", E_USER_DEPRECATED);
     $jsf = new JavascriptFactory();
     return $jsf->getChartJs($this, $elemId);
 }
예제 #3
0
 /**
  * Outputs the link to the Google JSAPI
  *
  *
  * @deprecated 3.1.0 Manual script tag location output is no longer needed,
  *                   lava.js injects the script into the head.
  *
  * @access public
  * @since  2.3.0
  * @return string Google Chart API and lava.js script blocks
  */
 public function jsapi()
 {
     trigger_error('Using the jsapi() method is deprecated since lava.js injects the jsapi into the head.', E_USER_DEPRECATED);
     return $this->jsFactory->getCoreJs();
 }