diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php
index 92f2cb62308..947b3800d60 100644
--- a/htdocs/core/lib/functions.lib.php
+++ b/htdocs/core/lib/functions.lib.php
@@ -2890,188 +2890,6 @@ function dol_substr($string, $start, $length, $stringencoding='', $trunconbytes=
}
-/**
- * Show a javascript graph.
- * Do not use this function anymore. Use DolGraph class instead.
- *
- * @param string $htmlid Html id name
- * @param int $width Width in pixel
- * @param int $height Height in pixel
- * @param array $data Data array
- * @param int $showlegend 1 to show legend, 0 otherwise
- * @param string $type Type of graph ('pie', 'barline')
- * @param int $showpercent Show percent (with type='pie' only)
- * @param string $url Param to add an url to click values
- * @param int $combineother 0=No combine, 0.05=Combine if lower than 5%
- * @param int $shownographyet Show graph to say there is not enough data
- * @return void
- * @deprecated
- * @see DolGraph
- */
-function dol_print_graph($htmlid,$width,$height,$data,$showlegend=0,$type='pie',$showpercent=0,$url='',$combineother=0.05,$shownographyet=0)
-{
- dol_syslog(__FUNCTION__ . " is deprecated", LOG_WARNING);
-
- global $conf,$langs;
- global $theme_datacolor; // To have var kept when function is called several times
-
- if ($shownographyet)
- {
- print '
';
- print ''.$langs->trans("NotEnoughDataYet").'
';
- return;
- }
-
- if (empty($conf->use_javascript_ajax)) return;
- $jsgraphlib='flot';
- $datacolor=array();
-
- // Load colors of theme into $datacolor array
- $color_file = DOL_DOCUMENT_ROOT."/theme/".$conf->theme."/graph-color.php";
- if (is_readable($color_file))
- {
- include_once $color_file;
- if (isset($theme_datacolor))
- {
- $datacolor=array();
- foreach($theme_datacolor as $val)
- {
- $datacolor[]="#".sprintf("%02x",$val[0]).sprintf("%02x",$val[1]).sprintf("%02x",$val[2]);
- }
- }
- }
- print '';
-
- // We use Flot js lib
- if ($jsgraphlib == 'flot')
- {
- if ($type == 'pie')
- {
- // data is array('series'=>array(serie1,serie2,...),
- // 'seriestype'=>array('bar','line',...),
- // 'seriescolor'=>array(0=>'#999999',1=>'#999999',...)
- // 'xlabel'=>array(0=>labelx1,1=>labelx2,...));
- // serieX is array('label'=>'label', data=>val)
- print '
- ';
- }
- else if ($type == 'barline')
- {
- // data is array('series'=>array(serie1,serie2,...),
- // 'seriestype'=>array('bar','line',...),
- // 'seriescolor'=>array(0=>'#999999',1=>'#999999',...)
- // 'xlabel'=>array(0=>labelx1,1=>labelx2,...));
- // serieX is array('label'=>'label', data=>array(0=>y1,1=>y2,...)) with same nb of value than into xlabel
- print '
- ';
- }
- else print 'BadValueForParameterType';
- }
-}
-
/**
* Truncate a string to a particular length adding '...' if string larger than length.
* If length = max length+1, we do no truncate to avoid having just 1 char replaced with '...'.