diff --git a/htdocs/lib/functions.lib.php b/htdocs/lib/functions.lib.php index 9362440bdb8..c0a444fcc84 100644 --- a/htdocs/lib/functions.lib.php +++ b/htdocs/lib/functions.lib.php @@ -3407,12 +3407,13 @@ function dol_eval($s) return 1; } -/** - * \brief For replace glob() function - */ + if (! function_exists('glob')) { - function glob($pattern) + /** + * \brief For replace glob() function + */ + function glob($pattern) { #get pathname (everything up until the last / or \) $path=$output=null; @@ -3480,9 +3481,9 @@ function pattern_match($pattern,$string) } /** - * \brief Return img flag of country for a language code or country code - * \param codelang Language code (en_IN, fr_CA...) or Country code (IN, FR) - * \return string HTML img string with flag. + * Return img flag of country for a language code or country code + * @param codelang Language code (en_IN, fr_CA...) or Country code (IN, FR) + * @return string HTML img string with flag. */ function picto_from_langcode($codelang) { @@ -3506,17 +3507,4 @@ function picto_from_langcode($codelang) return $ret; } -/** - * \brief Define the style of background color of line - */ -function bcStyle($impair='impair', $pair='pair') -{ - $bc=array(); - - $bc[0]='class="'.$impair.'"'; - $bc[1]='class="'.$pair.'"'; - - return $bc; -} - ?> \ No newline at end of file diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index d17efe5025c..8d89b8b3d76 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -697,7 +697,7 @@ if (! defined('NOREQUIRETRAN')) } // Define some constants used for style of arrays -$bc = bcStyle(); +$bc=array(0=>'class="impair"',1=>'class="pair"'); // Constants used to defined number of lines in textarea if (empty($conf->browser->firefox))