This commit is contained in:
Laurent Destailleur 2012-03-19 17:18:11 +01:00
parent 5759523c7a
commit 3383d314c9
63 changed files with 2674 additions and 2589 deletions

View File

@ -205,7 +205,7 @@ print '</tr>';
print '<tr class="impair">'; print '<tr class="impair">';
print '<td width="100">'.$langs->trans("Title").'</td>'; print '<td width="100">'.$langs->trans("Title").'</td>';
print '<td><input type="text" name="external_rss_title_'.($lastexternalrss+1).'" value="'.@constant("EXTERNAL_RSS_TITLE_" . ($lastexternalrss+1)).'" size="64"></td>'; print '<td><input type="text" name="external_rss_title_'.($lastexternalrss+1).'" value="'.@constant("EXTERNAL_RSS_TITLE_" . ($lastexternalrss+1)).'" size="64"></td>';
print '<td>April,<br>LinuxFR,<br>Lolix</td>'; print '<td>An interesting RSS feed</td>';
print '</tr>'; print '</tr>';
print '<tr class="pair">'; print '<tr class="pair">';

View File

@ -206,8 +206,8 @@ class Propal extends CommonObject
/** /**
* Adding line of fixed discount in the proposal in DB * Adding line of fixed discount in the proposal in DB
* *
* @param int @idremise Id of fixed discount * @param int $idremise Id of fixed discount
* @return int >0 si ok, <0 si ko * @return int >0 if OK, <0 if KO
*/ */
function insert_discount($idremise) function insert_discount($idremise)
{ {
@ -828,6 +828,7 @@ class Propal extends CommonObject
/** /**
* Insert into DB a proposal object completely defined by its data members (ex, results from copy). * Insert into DB a proposal object completely defined by its data members (ex, results from copy).
*
* @param User $user User that create * @param User $user User that create
* @return int Id of the new object if ok, <0 if ko * @return int Id of the new object if ok, <0 if ko
* @see create * @see create

View File

@ -48,6 +48,7 @@ class box_external_rss extends ModeleBoxes
* Constructor * Constructor
* *
* @param DoliDB $db Database handler * @param DoliDB $db Database handler
* @param string $param More parameters
*/ */
function box_external_rss($db,$param) function box_external_rss($db,$param)
{ {

View File

@ -39,21 +39,22 @@ class box_prospect extends ModeleBoxes
var $depends = array("societe"); var $depends = array("societe");
var $db; var $db;
var $param;
var $info_box_head = array(); var $info_box_head = array();
var $info_box_contents = array(); var $info_box_contents = array();
/** /**
* Constructor * Constructor
*
* @param DoliDB $db Database handler
*/ */
function box_prospect($DB,$param) function box_prospect($db)
{ {
global $langs; global $langs;
$langs->load("boxes"); $langs->load("boxes");
$this->db=$DB; $this->db=$db;
$this->param=$param;
$this->boxlabel=$langs->transnoentitiesnoconv("BoxLastProspects"); $this->boxlabel=$langs->transnoentitiesnoconv("BoxLastProspects");
} }

View File

@ -46,7 +46,7 @@ class Canvas
/** /**
* Constructor * Constructor
* *
* @param DoliDB $DB Database handler * @param DoliDB $db Database handler
* @param string $actiontype Action type ('create', 'view', 'edit', 'list') * @param string $actiontype Action type ('create', 'view', 'edit', 'list')
*/ */
function __construct($db, $actiontype='view') function __construct($db, $actiontype='view')

View File

@ -38,8 +38,9 @@ abstract class CommonDocGenerator
/** /**
* Define array with couple subtitution key => subtitution value * Define array with couple subtitution key => subtitution value
* *
* @param $user User * @param User $user User
* @param $outputlangs Language object for output * @param Translate $outputlangs Language object for output
* @return array Array of substitution key->code
*/ */
function get_substitutionarray_user($user,$outputlangs) function get_substitutionarray_user($user,$outputlangs)
{ {
@ -61,8 +62,9 @@ abstract class CommonDocGenerator
/** /**
* Define array with couple subtitution key => subtitution value * Define array with couple subtitution key => subtitution value
* *
* @param $mysoc * @param Societe $mysoc Object thirdparty
* @param $outputlangs Language object for output * @param Translate $outputlangs Language object for output
* @return array Array of substitution key->code
*/ */
function get_substitutionarray_mysoc($mysoc,$outputlangs) function get_substitutionarray_mysoc($mysoc,$outputlangs)
{ {
@ -103,8 +105,9 @@ abstract class CommonDocGenerator
/** /**
* Define array with couple subtitution key => subtitution value * Define array with couple subtitution key => subtitution value
* *
* @param $object * @param Object $object Object
* @param $outputlangs Language object for output * @param Translate $outputlangs Language object for output
* @return array Array of substitution key->code
*/ */
function get_substitutionarray_thirdparty($object,$outputlangs) function get_substitutionarray_thirdparty($object,$outputlangs)
{ {

View File

@ -2433,8 +2433,8 @@ abstract class CommonObject
* *
* @param string $action GET/POST action * @param string $action GET/POST action
* @param array $line Selected object line to output * @param array $line Selected object line to output
* @param string $var Is it a an odd line * @param string $var Is it a an odd line (true)
* @param int $num Number of line * @param int $num Number of line (0)
* @param int $i I * @param int $i I
* @param int $dateSelector 1=Show also date range input fields * @param int $dateSelector 1=Show also date range input fields
* @param string $seller Object of seller third party * @param string $seller Object of seller third party
@ -2443,7 +2443,7 @@ abstract class CommonObject
* @param HookManager $hookmanager Hook manager * @param HookManager $hookmanager Hook manager
* @return void * @return void
*/ */
function printObjectLine($action,$line,$var=true,$num=0,$i=0,$dateSelector=0,$seller,$buyer,$selected=0,$hookmanager=false) function printObjectLine($action,$line,$var,$num,$i,$dateSelector,$seller,$buyer,$selected=0,$hookmanager=false)
{ {
global $conf,$langs,$user; global $conf,$langs,$user;
global $form,$bc,$bcdd; global $form,$bc,$bcdd;

View File

@ -35,7 +35,7 @@ class GenericObject extends CommonObject
/** /**
* Constructor * Constructor
* *
* @param DoliDB $DB Database handler * @param DoliDB $db Database handler
*/ */
function __construct($db) function __construct($db)
{ {

View File

@ -44,7 +44,7 @@ class HookManager
/** /**
* Constructor * Constructor
* *
* @param DoliDB $DB Handler acces base de donnees * @param DoliDB $db Handler acces base de donnees
*/ */
function __construct($db) function __construct($db)
{ {

View File

@ -389,7 +389,7 @@ class Form
* Show a text with a picto and a tooltip on picto * Show a text with a picto and a tooltip on picto
* *
* @param string $text Text to show * @param string $text Text to show
* @param string $htmltooltip Content of tooltip * @param string $htmltext Content of tooltip
* @param int $direction 1=Icon is after text, -1=Icon is before text, 0=no icon * @param int $direction 1=Icon is after text, -1=Icon is before text, 0=no icon
* @param string $type Type of picto (info, help, warning, superadmin...) * @param string $type Type of picto (info, help, warning, superadmin...)
* @param string $extracss Add a CSS style to td tags * @param string $extracss Add a CSS style to td tags
@ -651,7 +651,7 @@ class Form
* @param int $showempty Add an empty field * @param int $showempty Add an empty field
* @param int $showtype Show third party type in combolist (customer, prospect or supplier) * @param int $showtype Show third party type in combolist (customer, prospect or supplier)
* @param int $forcecombo Force to use combo box * @param int $forcecombo Force to use combo box
@param array $event Event options * @param array $event Event options
* @return string HTML string with * @return string HTML string with
*/ */
function select_company($selected='',$htmlname='socid',$filter='',$showempty=0, $showtype=0, $forcecombo=0, $event=array()) function select_company($selected='',$htmlname='socid',$filter='',$showempty=0, $showtype=0, $forcecombo=0, $event=array())
@ -811,7 +811,7 @@ class Form
* @param int $socid Id ot third party or 0 for all * @param int $socid Id ot third party or 0 for all
* @param string $selected Id contact pre-selectionne * @param string $selected Id contact pre-selectionne
* @param string $htmlname Name of HTML field ('none' for a not editable field) * @param string $htmlname Name of HTML field ('none' for a not editable field)
* @param int $show_empty 0=no empty value, 1=add an empty value * @param int $showempty 0=no empty value, 1=add an empty value
* @param string $exclude List of contacts id to exclude * @param string $exclude List of contacts id to exclude
* @param string $limitto Disable answers that are not id in this array list * @param string $limitto Disable answers that are not id in this array list
* @param string $showfunction Add function into label * @param string $showfunction Add function into label
@ -1055,6 +1055,7 @@ class Form
* @param int $status -1=Return all products, 0=Products not on sell, 1=Products on sell * @param int $status -1=Return all products, 0=Products not on sell, 1=Products on sell
* @param int $finished 2=all, 1=finished, 0=raw material * @param int $finished 2=all, 1=finished, 0=raw material
* @param string $selected_input_value Value of preselected input text (with ajax) * @param string $selected_input_value Value of preselected input text (with ajax)
* @param int $hide_label Hide label
* @return void * @return void
*/ */
function select_produits($selected='',$htmlname='productid',$filtertype='',$limit=20,$price_level=0,$status=1,$finished=2,$selected_input_value='',$hidelabel=0) function select_produits($selected='',$htmlname='productid',$filtertype='',$limit=20,$price_level=0,$status=1,$finished=2,$selected_input_value='',$hidelabel=0)
@ -1312,7 +1313,7 @@ class Form
* @param string $filtre For a SQL filter * @param string $filtre For a SQL filter
* @return void * @return void
*/ */
function select_produits_fournisseurs($socid,$selected='',$htmlname='productid',$filtertype='',$filtre) function select_produits_fournisseurs($socid,$selected='',$htmlname='productid',$filtertype='',$filtre='')
{ {
global $langs,$conf; global $langs,$conf;
global $price_level, $status, $finished; global $price_level, $status, $finished;
@ -1576,7 +1577,7 @@ class Form
* @param int $showempty Add an empty field * @param int $showempty Add an empty field
* @return void * @return void
*/ */
function select_address($selected='', $socid, $htmlname='address_id',$showempty=0) function select_address($selected, $socid, $htmlname='address_id',$showempty=0)
{ {
// On recherche les utilisateurs // On recherche les utilisateurs
$sql = "SELECT a.rowid, a.label"; $sql = "SELECT a.rowid, a.label";
@ -2064,6 +2065,7 @@ class Form
* @param string $select_name HTML field name * @param string $select_name HTML field name
* @param int $maxlength Maximum length for labels * @param int $maxlength Maximum length for labels
* @param int $excludeafterid Exclude all categories after this leaf in category tree. * @param int $excludeafterid Exclude all categories after this leaf in category tree.
* @return void
*/ */
function select_all_categories($type, $selected='', $select_name="", $maxlength=64, $excludeafterid=0) function select_all_categories($type, $selected='', $select_name="", $maxlength=64, $excludeafterid=0)
{ {
@ -2606,7 +2608,7 @@ class Form
* *
* @param string $page Page URL where form is shown * @param string $page Page URL where form is shown
* @param int $selected Value pre-selected * @param int $selected Value pre-selected
* @param string $htmlname Nom du formulaire select. Si none, non modifiable * @param string $htmlname Nom du formulaire select. Si 'none', non modifiable. Example 'remise_id'.
* @param int $socid Third party id * @param int $socid Third party id
* @param float $amount Total amount available * @param float $amount Total amount available
* @param string $filter SQL filter on discounts * @param string $filter SQL filter on discounts
@ -2614,7 +2616,7 @@ class Form
* @param string $more More string to add * @param string $more More string to add
* @return void * @return void
*/ */
function form_remise_dispo($page, $selected='', $htmlname='remise_id', $socid, $amount, $filter='', $maxvalue=0, $more='') function form_remise_dispo($page, $selected, $htmlname, $socid, $amount, $filter='', $maxvalue=0, $more='')
{ {
global $conf,$langs; global $conf,$langs;
if ($htmlname != "none") if ($htmlname != "none")
@ -2855,7 +2857,7 @@ class Form
* @param Societe $societe_acheteuse Object societe acheteuse * @param Societe $societe_acheteuse Object societe acheteuse
* @param int $idprod Id product * @param int $idprod Id product
* @param int $info_bits Miscellaneous information on line * @param int $info_bits Miscellaneous information on line
* @param type ''=Unknown, 0=Product, 1=Service (Used if idprod not defined) * @param string $type ''=Unknown, 0=Product, 1=Service (Used if idprod not defined)
* Si vendeur non assujeti a TVA, TVA par defaut=0. Fin de regle. * Si vendeur non assujeti a TVA, TVA par defaut=0. Fin de regle.
* Si le (pays vendeur = pays acheteur) alors la TVA par defaut=TVA du produit vendu. Fin de regle. * Si le (pays vendeur = pays acheteur) alors la TVA par defaut=TVA du produit vendu. Fin de regle.
* Si (vendeur et acheteur dans Communaute europeenne) et bien vendu = moyen de transports neuf (auto, bateau, avion), TVA par defaut=0 (La TVA doit etre paye par l'acheteur au centre d'impots de son pays et non au vendeur). Fin de regle. * Si (vendeur et acheteur dans Communaute europeenne) et bien vendu = moyen de transports neuf (auto, bateau, avion), TVA par defaut=0 (La TVA doit etre paye par l'acheteur au centre d'impots de son pays et non au vendeur). Fin de regle.
@ -3428,7 +3430,7 @@ class Form
/** /**
* Return an html string with a select combo box to choose yes or no * Return an html string with a select combo box to choose yes or no
* *
* @param string $name Name of html select field * @param string $htmlname Name of html select field
* @param string $value Pre-selected value * @param string $value Pre-selected value
* @param int $option 0 return yes/no, 1 return 1/0 * @param int $option 0 return yes/no, 1 return 1/0
* @param bool $disabled true or false * @param bool $disabled true or false

View File

@ -66,7 +66,7 @@ class FormFile
if ($conf->global->MAIN_USE_JQUERY_FILEUPLOAD) if ($conf->global->MAIN_USE_JQUERY_FILEUPLOAD)
{ {
return $this->_form_ajaxfileupload($object); return $this->_formAjaxFileUpload($object);
} }
else else
{ {
@ -779,7 +779,7 @@ class FormFile
* @param Object $object Object to use * @param Object $object Object to use
* @return void * @return void
*/ */
private function _form_ajaxfileupload($object) private function _formAjaxFileUpload($object)
{ {
global $langs; global $langs;

View File

@ -71,7 +71,7 @@ class FormMail
/** /**
* Constructor * Constructor
* *
* @param DoliDB $DB Database handler * @param DoliDB $db Database handler
*/ */
function FormMail($db) function FormMail($db)
{ {

View File

@ -30,6 +30,7 @@ class InfoBox
/** /**
* Return array of boxes qualified for area and user * Return array of boxes qualified for area and user
* *
* @param DoliDB $db Database handler
* @param string $mode 'available' or 'activated' * @param string $mode 'available' or 'activated'
* @param string $zone Name or area (-1 for all, 0 for Homepage, 1 for xxx, ...) * @param string $zone Name or area (-1 for all, 0 for Homepage, 1 for xxx, ...)
* @param User $user Objet user to filter (used only if $zone >= 0) * @param User $user Objet user to filter (used only if $zone >= 0)
@ -140,6 +141,7 @@ class InfoBox
/** /**
* Save order of boxes for area and user * Save order of boxes for area and user
* *
* @param DoliDB $db Database handler
* @param string $zone Name of area (0 for Homepage, ...) * @param string $zone Name of area (0 for Homepage, ...)
* @param string $boxorder List of boxes with correct order 'A:123,456,...-B:789,321...' * @param string $boxorder List of boxes with correct order 'A:123,456,...-B:789,321...'
* @param int $userid Id of user * @param int $userid Id of user

View File

@ -50,7 +50,7 @@ class Interfaces
* @param string $action Trigger event code * @param string $action Trigger event code
* @param Object $object Objet concern * @param Object $object Objet concern
* @param User $user Objet user * @param User $user Objet user
* @param Lang $lang Objet lang * @param Lang $langs Objet lang
* @param Conf $conf Objet conf * @param Conf $conf Objet conf
* @return int Nb of triggers ran if no error, -Nb of triggers with errors otherwise. * @return int Nb of triggers ran if no error, -Nb of triggers with errors otherwise.
*/ */

View File

@ -1012,6 +1012,7 @@ class Ldap
* Required by Active Directory * Required by Active Directory
* *
* @param string $hex * @param string $hex
* @return string little endian
*/ */
function littleEndian($hex) function littleEndian($hex)
{ {
@ -1027,6 +1028,7 @@ class Ldap
* Required by Active Directory * Required by Active Directory
* *
* @param string $ldapuser Login de l'utilisateur * @param string $ldapuser Login de l'utilisateur
* @return string Sid
*/ */
function getObjectSid($ldapUser) function getObjectSid($ldapUser)
{ {
@ -1056,7 +1058,7 @@ class Ldap
if (!$entry) if (!$entry)
{ {
// Si pas de r<EFBFBD>sultat on cherche dans le domaine // Si pas de resultat on cherche dans le domaine
$searchDN = $this->domain; $searchDN = $this->domain;
$i++; $i++;
} }
@ -1109,8 +1111,8 @@ class Ldap
* car conflit majuscule-minuscule. A n'utiliser que pour les pages * car conflit majuscule-minuscule. A n'utiliser que pour les pages
* 'Fiche LDAP' qui affiche champ lisibles par defaut. * 'Fiche LDAP' qui affiche champ lisibles par defaut.
* *
* @param checkDn DN de recherche (Ex: ou=users,cn=my-domain,cn=com) * @param string $checkDn DN de recherche (Ex: ou=users,cn=my-domain,cn=com)
* @param filter Filtre de recherche (ex: (sn=nom_personne) ) * @param string $filter Filtre de recherche (ex: (sn=nom_personne) )
* @return array Tableau des reponses (cle en minuscule-valeur) * @return array Tableau des reponses (cle en minuscule-valeur)
*/ */
function search($checkDn, $filter) function search($checkDn, $filter)

View File

@ -25,18 +25,18 @@ class RssParser
var $db; var $db;
var $error; var $error;
protected $_format=''; private $_format='';
protected $_urlRSS; private $_urlRSS;
protected $_language; private $_language;
protected $_generator; private $_generator;
protected $_copyright; private $_copyright;
protected $_lastbuilddate; private $_lastbuilddate;
protected $_imageurl; private $_imageurl;
protected $_link; private $_link;
protected $_title; private $_title;
protected $_description; private $_description;
protected $_lastfetchdate; // Last successful fetch private $_lastfetchdate; // Last successful fetch
protected $_rssarray=array(); private $_rssarray=array();
/** /**
* getFormat * getFormat

View File

@ -19,7 +19,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
require('../../../../main.inc.php'); ?> require('../../../../main.inc.php');
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- <!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net * FCKeditor - The text editor for Internet - http://www.fckeditor.net

View File

@ -19,7 +19,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
require('../../../../main.inc.php'); ?> require('../../../../main.inc.php');
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- <!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net * FCKeditor - The text editor for Internet - http://www.fckeditor.net

View File

@ -19,7 +19,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
require('../../../../main.inc.php'); ?> require('../../../../main.inc.php');
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- <!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net * FCKeditor - The text editor for Internet - http://www.fckeditor.net

View File

@ -19,7 +19,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
require('../../../../main.inc.php'); ?> require('../../../../main.inc.php');
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- <!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net * FCKeditor - The text editor for Internet - http://www.fckeditor.net

View File

@ -19,7 +19,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
require('../../../../main.inc.php'); ?> require('../../../../main.inc.php');
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- <!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net * FCKeditor - The text editor for Internet - http://www.fckeditor.net

View File

@ -23,6 +23,11 @@
* connector. * connector.
*/ */
/**
* SetXmlHeaders
*
* @return void
*/
function SetXmlHeaders() function SetXmlHeaders()
{ {
ob_end_clean(); ob_end_clean();

View File

@ -10,8 +10,7 @@ if ( !isset( $_FILES ) ) {
$_FILES = $HTTP_POST_FILES ; $_FILES = $HTTP_POST_FILES ;
} }
if ( !defined( 'DIRECTORY_SEPARATOR' ) ) { if (! defined('DIRECTORY_SEPARATOR'))
define( 'DIRECTORY_SEPARATOR', {
strtoupper(substr(PHP_OS, 0, 3) == 'WIN') ? '\\' : '/' define('DIRECTORY_SEPARATOR', strtoupper(substr(PHP_OS, 0, 3) == 'WIN') ? '\\' : '/');
);
} }

View File

@ -667,8 +667,8 @@ function pdf_pagefoot(&$pdf,$outputlangs,$paramfreetext,$fromcompany,$marge_bass
* @param PDF &$pdf Object PDF * @param PDF &$pdf Object PDF
* @param object $object Object * @param object $object Object
* @param Translate $outputlangs Object lang * @param Translate $outputlangs Object lang
* @param int $curx X * @param int $posx X
* @param int $cury Y * @param int $posy Y
* @param int $align Align * @param int $align Align
* @param string $default_font_size Font size * @param string $default_font_size Font size
* @param HookManager $hookmanager Hook manager object * @param HookManager $hookmanager Hook manager object

View File

@ -242,7 +242,6 @@ class SimpleOpenID
/** /**
* GetIdentity * GetIdentity
* *
* @param string $a Server
* @return void * @return void
*/ */
function GetIdentity() function GetIdentity()
@ -253,7 +252,6 @@ class SimpleOpenID
/** /**
* SetOpenIDServer * SetOpenIDServer
* *
* @param string $a Server
* @return void * @return void
*/ */
function GetError() function GetError()
@ -265,7 +263,8 @@ class SimpleOpenID
/** /**
* ErrorStore * ErrorStore
* *
* @param string $a Server * @param string $code Code
* @param string $desc Description
* @return void * @return void
*/ */
function ErrorStore($code, $desc = null) function ErrorStore($code, $desc = null)
@ -280,14 +279,16 @@ class SimpleOpenID
/** /**
* IsError * IsError
* *
* @param string $a Server
* @return void * @return void
*/ */
function IsError() function IsError()
{ {
if (count($this->error) > 0){ if (count($this->error) > 0)
{
return true; return true;
}else{ }
else
{
return false; return false;
} }
} }
@ -295,7 +296,7 @@ class SimpleOpenID
/** /**
* splitResponse * splitResponse
* *
* @param string $a Server * @param string $response Server
* @return void * @return void
*/ */
function splitResponse($response) function splitResponse($response)
@ -315,7 +316,7 @@ class SimpleOpenID
/** /**
* OpenID_Standarize * OpenID_Standarize
* *
* @param string $a Server * @param string $openidçidentity Server
* @return void * @return void
*/ */
function OpenID_Standarize($openid_identity = null) function OpenID_Standarize($openid_identity = null)
@ -434,7 +435,6 @@ class SimpleOpenID
/** /**
* GetRedirectURL * GetRedirectURL
* *
* @param string $a Server
* @return void * @return void
*/ */
function GetRedirectURL() function GetRedirectURL()
@ -459,7 +459,6 @@ class SimpleOpenID
/** /**
* Redirect * Redirect
* *
* @param string $a Server
* @return void * @return void
*/ */
function Redirect() function Redirect()
@ -480,7 +479,6 @@ class SimpleOpenID
/** /**
* ValidateWithServer * ValidateWithServer
* *
* @param string $a Server
* @return void * @return void
*/ */
function ValidateWithServer() function ValidateWithServer()

View File

@ -26,10 +26,11 @@
/** /**
* Core function to output top menu smartphone * Core function to output top menu smartphone
* *
* @param $db * @param DoliDB $db Database handler
* @param $atarget * @param string $atarget Target
* @param $type_user 0=Internal,1=External,2=All * @param int $type_user 0=Internal,1=External,2=All
* @param $limitmenuto To limit menu to a top or left menu value * @param string $limitmenuto To limit menu to a top or left menu value
* @return void
*/ */
function print_smartphone_menu($db,$atarget,$type_user,$limitmenuto) function print_smartphone_menu($db,$atarget,$type_user,$limitmenuto)
{ {
@ -141,34 +142,66 @@ function print_smartphone_menu($db,$atarget,$type_user,$limitmenuto)
print "\n"; print "\n";
} }
/**
* Output menu entry
*
* @param string $theme Theme
* @return void
*/
function print_start_menu_array($theme='c') function print_start_menu_array($theme='c')
{ {
print '<ul data-role="listview" data-theme="'.$theme.'">'; print '<ul data-role="listview" data-theme="'.$theme.'">';
print "\n"; print "\n";
} }
/**
* Output start submenu entry
*
* @return void
*/
function print_start_submenu_array() function print_start_submenu_array()
{ {
print '<ul>'; print '<ul>';
print "\n"; print "\n";
} }
/**
* Output start menu entry
*
* @return void
*/
function print_start_menu_entry() function print_start_menu_entry()
{ {
print '<li>'; print '<li>';
} }
/**
* Output menu entry
*
* @param string $text Text
* @return void
*/
function print_text_menu_entry($text) function print_text_menu_entry($text)
{ {
print $text; print $text;
} }
/**
* Output end menu entry
*
* @return void
*/
function print_end_menu_entry() function print_end_menu_entry()
{ {
print '</li>'; print '</li>';
print "\n"; print "\n";
} }
/**
* Output end menu
*
* @return void
*/
function print_end_menu() function print_end_menu()
{ {
print '</ul>'; print '</ul>';

View File

@ -25,8 +25,8 @@
/** /**
* Class to manage smartphone menu smartphone (for internal users) * Class to manage smartphone menu smartphone (for internal users)
*/ */
class MenuSmart { class MenuSmart
{
var $db; var $db;
var $require_left=array("smartphone_backoffice"); // Si doit etre en phase avec un gestionnaire de menu particulier var $require_left=array("smartphone_backoffice"); // Si doit etre en phase avec un gestionnaire de menu particulier
var $hideifnotallowed=0; // Put 0 for back office menu, 1 for front office menu var $hideifnotallowed=0; // Put 0 for back office menu, 1 for front office menu

View File

@ -23,10 +23,10 @@
/** /**
* \class MenuSmart * Class to manage smartphone menu smartphone (for external users)
* \brief Class to manage smartphone menu smartphone (for external users)
*/ */
class MenuSmart { class MenuSmart
{
var $require_left=array("smartphone_frontoffice"); // Si doit etre en phase avec un gestionnaire de menu particulier var $require_left=array("smartphone_frontoffice"); // Si doit etre en phase avec un gestionnaire de menu particulier
var $hideifnotallowed=1; // Put 0 for back office menu, 1 for front office menu var $hideifnotallowed=1; // Put 0 for back office menu, 1 for front office menu
@ -36,7 +36,7 @@ class MenuSmart {
/** /**
* Constructor * Constructor
* *
* @param DoliDB $DB Database handler * @param DoliDB $db Database handler
*/ */
function MenuSmart($db) function MenuSmart($db)
{ {
@ -47,7 +47,7 @@ class MenuSmart {
/** /**
* Show menu * Show menu
* *
* @param limitmenuto To limit menu to a top or left menu value * @param string $limitmenuto To limit menu to a top or left menu value
*/ */
function showmenu($limitmenuto) function showmenu($limitmenuto)
{ {

View File

@ -108,7 +108,11 @@ function print_auguria_menu($db,$atarget,$type_user)
} }
/**
* Output start menu entry
*
* @return void
*/
function print_start_menu_array_auguria() function print_start_menu_array_auguria()
{ {
global $conf; global $conf;
@ -116,6 +120,12 @@ function print_start_menu_array_auguria()
else print '<ul class="tmenu">'; else print '<ul class="tmenu">';
} }
/**
* Output menu entry
*
* @param string $idsel Text
* @return void
*/
function print_start_menu_entry_auguria($idsel) function print_start_menu_entry_auguria($idsel)
{ {
global $conf; global $conf;
@ -123,6 +133,12 @@ function print_start_menu_entry_auguria($idsel)
else print '<li class="tmenu" id="mainmenutd_'.$idsel.'">'; else print '<li class="tmenu" id="mainmenutd_'.$idsel.'">';
} }
/**
* Output menu entry
*
* @param string $text Text
* @return void
*/
function print_text_menu_entry_auguria($text) function print_text_menu_entry_auguria($text)
{ {
global $conf; global $conf;
@ -131,6 +147,11 @@ function print_text_menu_entry_auguria($text)
print '</span>'; print '</span>';
} }
/**
* Output end menu entry
*
* @return void
*/
function print_end_menu_entry_auguria() function print_end_menu_entry_auguria()
{ {
global $conf; global $conf;
@ -139,6 +160,11 @@ function print_end_menu_entry_auguria()
print "\n"; print "\n";
} }
/**
* Output menu array
*
* @return void
*/
function print_end_menu_array_auguria() function print_end_menu_array_auguria()
{ {
global $conf; global $conf;

View File

@ -511,6 +511,12 @@ function print_start_menu_array()
else print '<ul class="tmenu">'; else print '<ul class="tmenu">';
} }
/**
* Output start menu entry
*
* @param string $idsel Text
* @return void
*/
function print_start_menu_entry($idsel) function print_start_menu_entry($idsel)
{ {
global $conf; global $conf;
@ -518,6 +524,12 @@ function print_start_menu_entry($idsel)
else print '<li class="tmenu" id="mainmenutd_'.$idsel.'">'; else print '<li class="tmenu" id="mainmenutd_'.$idsel.'">';
} }
/**
* Output menu entry
*
* @param string $text Text
* @return void
*/
function print_text_menu_entry($text) function print_text_menu_entry($text)
{ {
global $conf; global $conf;
@ -526,6 +538,11 @@ function print_text_menu_entry($text)
print '</span>'; print '</span>';
} }
/**
* Output end menu entry
*
* @return void
*/
function print_end_menu_entry() function print_end_menu_entry()
{ {
global $conf; global $conf;
@ -534,6 +551,11 @@ function print_end_menu_entry()
print "\n"; print "\n";
} }
/**
* Output menu array
*
* @return void
*/
function print_end_menu_array() function print_end_menu_array()
{ {
global $conf; global $conf;

View File

@ -71,7 +71,11 @@ class MenuTop
} }
/**
* Output menu entry
*
* @return void
*/
function print_start_menu_array_empty() function print_start_menu_array_empty()
{ {
global $conf; global $conf;
@ -79,6 +83,12 @@ function print_start_menu_array_empty()
else print '<ul class="tmenu">'; else print '<ul class="tmenu">';
} }
/**
* Output start menu entry
*
* @param string $idsel Text
* @return void
*/
function print_start_menu_entry_empty($idsel) function print_start_menu_entry_empty($idsel)
{ {
global $conf; global $conf;
@ -86,6 +96,12 @@ function print_start_menu_entry_empty($idsel)
else print '<li class="tmenu" id="mainmenutd_'.$idsel.'">'; else print '<li class="tmenu" id="mainmenutd_'.$idsel.'">';
} }
/**
* Output menu entry
*
* @param string $text Text
* @return void
*/
function print_text_menu_entry_empty($text) function print_text_menu_entry_empty($text)
{ {
global $conf; global $conf;
@ -94,6 +110,11 @@ function print_text_menu_entry_empty($text)
print '</span>'; print '</span>';
} }
/**
* Output end menu entry
*
* @return void
*/
function print_end_menu_entry_empty() function print_end_menu_entry_empty()
{ {
global $conf; global $conf;
@ -102,6 +123,11 @@ function print_end_menu_entry_empty()
print "\n"; print "\n";
} }
/**
* Output menu array
*
* @return void
*/
function print_end_menu_array_empty() function print_end_menu_array_empty()
{ {
global $conf; global $conf;

View File

@ -74,8 +74,8 @@ Class pdf_expedition_merou extends ModelePdfExpedition
/** /**
* Fonction generant le document sur le disque * Fonction generant le document sur le disque
* *
* @param object Objet expedition a generer (ou id si ancienne methode) * @param Object &$object Objet expedition a generer (ou id si ancienne methode)
* @param outputlangs Lang output object * @param Translate $outputlangs Lang output object
* @return int 1=ok, 0=ko * @return int 1=ok, 0=ko
*/ */
function write_file(&$object, $outputlangs) function write_file(&$object, $outputlangs)

View File

@ -76,7 +76,7 @@ Class pdf_expedition_rouget extends ModelePdfExpedition
/** /**
* Fonction generant le document sur le disque * Fonction generant le document sur le disque
* *
* @param Object $object Objet expedition a generer (ou id si ancienne methode) * @param Object &$object Objet expedition a generer (ou id si ancienne methode)
* @param Translate $outputlangs Lang output object * @param Translate $outputlangs Lang output object
* @return int 1=ok, 0=ko * @return int 1=ok, 0=ko
*/ */

View File

@ -120,7 +120,7 @@ class mod_expedition_ribera extends ModelNumRefExpedition
* Return next free value * Return next free value
* *
* @param Societe $objsoc Third party object * @param Societe $objsoc Third party object
* @param Object $shipment Shipment object * @param Object $objforref Shipment object
* @return string Next free value * @return string Next free value
*/ */
function expedition_get_num($objsoc,$objforref) function expedition_get_num($objsoc,$objforref)

View File

@ -132,7 +132,7 @@ class mod_expedition_safor extends ModelNumRefExpedition
* Return next free value * Return next free value
* *
* @param Societe $objsoc Third party object * @param Societe $objsoc Third party object
* @param Object $shipment Shipment object * @param Object $objforref Shipment object
* @return string Next free value * @return string Next free value
*/ */
function expedition_get_num($objsoc,$objforref) function expedition_get_num($objsoc,$objforref)

View File

@ -746,6 +746,7 @@ class pdf_oursin extends ModelePDFFactures
* @param string $tab_top Top position of table * @param string $tab_top Top position of table
* @param string $tab_height Height of table (rectangle) * @param string $tab_height Height of table (rectangle)
* @param int $nexY Y * @param int $nexY Y
* @param Object $object Object
* @param Translate $outputlangs Langs object * @param Translate $outputlangs Langs object
* @return void * @return void
*/ */

View File

@ -110,9 +110,9 @@ class mod_facture_mercure extends ModeleNumRefFactures
/** /**
* Return next value * Return next value
* *
* @param objsoc Object third party * @param Societe $objsoc Object third party
* @param facture Object invoice * @param Facture $facture Object invoice
* @param mode 'next' for next value or 'last' for last value * @param string $mode 'next' for next value or 'last' for last value
* @return string Value if OK, 0 if KO * @return string Value if OK, 0 if KO
*/ */
function getNextValue($objsoc,$facture,$mode='next') function getNextValue($objsoc,$facture,$mode='next')

View File

@ -114,11 +114,12 @@ class mod_facture_terre extends ModeleNumRefFactures
return true; return true;
} }
/** Return next value not used or last value used /**
* Return next value not used or last value used
* *
* @param objsoc Object third party * @param Societe $objsoc Object third party
* @param facture Object invoice * @param Facture $facture Object invoice
* @param mode 'next' for next value or 'last' for last value * @param string $mode 'next' for next value or 'last' for last value
* @return string Value * @return string Value
*/ */
function getNextValue($objsoc,$facture,$mode='next') function getNextValue($objsoc,$facture,$mode='next')

View File

@ -116,9 +116,9 @@ abstract class ModeleNumRefFactures
/** /**
* Renvoi prochaine valeur attribuee * Renvoi prochaine valeur attribuee
* *
* @param objsoc Objet societe * @param Societe $objsoc Objet societe
* @param facture Objet facture * @param Facture $facture Objet facture
* @return string Valeur * @return string Value
*/ */
function getNextValue($objsoc,$facture) function getNextValue($objsoc,$facture)
{ {

View File

@ -143,7 +143,7 @@ class mod_livraison_saphir extends ModeleNumRefDeliveryOrder
* Return next free ref * Return next free ref
* *
* @param Societe $objsoc Object thirdparty * @param Societe $objsoc Object thirdparty
* @param Object $livraison Objet livraison * @param Object $object Objet livraison
* @return string Texte descripif * @return string Texte descripif
*/ */
function livraison_get_num($objsoc=0,$object='') function livraison_get_num($objsoc=0,$object='')

View File

@ -152,10 +152,11 @@ class mod_codeclient_elephant extends ModeleThirdPartyCode
return $examplecust.'<br>'.$examplesup; return $examplecust.'<br>'.$examplesup;
} }
/** Return next value /**
* Return next value
* *
* @param objsoc Object third party * @param Societe $objsoc Object third party
* @param $type Client ou fournisseur (0:customer, 1:supplier) * @param int $type Client ou fournisseur (0:customer, 1:supplier)
* @return string Value if OK, '' if module not configured, <0 if KO * @return string Value if OK, '' if module not configured, <0 if KO
*/ */
function getNextValue($objsoc=0,$type=-1) function getNextValue($objsoc=0,$type=-1)

View File

@ -247,7 +247,7 @@ class mod_codeclient_monkey extends ModeleThirdPartyCode
* Renvoi si un code respecte la syntaxe * Renvoi si un code respecte la syntaxe
* *
* @param string $code Code a verifier * @param string $code Code a verifier
* * @return int 0 si OK, <0 si KO * @return int 0 si OK, <0 si KO
*/ */
function verif_syntax($code) function verif_syntax($code)
{ {

View File

@ -100,9 +100,9 @@ class mod_codecompta_aquarium extends ModeleAccountancyCode
/** /**
* Set accountancy account code for a third party into this->code * Set accountancy account code for a third party into this->code
* *
* @param db Database handler * @param DoliDB $db Database handler
* @param societe Third party object * @param Societe $societe Third party object
* @param type 'customer' or 'supplier' * @param string $type 'customer' or 'supplier'
* @return int >=0 if OK, <0 if KO * @return int >=0 if OK, <0 if KO
*/ */
function get_code($db, $societe, $type) function get_code($db, $societe, $type)
@ -138,10 +138,10 @@ class mod_codecompta_aquarium extends ModeleAccountancyCode
/** /**
* Return if a code is available * Return if a code is available
* *
* @param db Database handler * @param DoliDB $db Database handler
* @param code Code of third party * @param string $code Code of third party
* @param societe Object third party * @param Societe $societe Object third party
* @param type 'supplier' or 'customer' * @param string $type 'supplier' or 'customer'
* @return int 0 if OK but not available, >0 if OK and available, <0 if KO * @return int 0 if OK but not available, >0 if OK and available, <0 if KO
*/ */
function verif($db, $code, $societe, $type) function verif($db, $code, $societe, $type)

View File

@ -115,8 +115,9 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
/** /**
* Write the invoice as a document onto disk * Write the invoice as a document onto disk
* @param object Object invoice to build (or id if old method) *
* @param outputlangs Lang object for output language * @param Object $object Object invoice to build (or id if old method)
* @param Translate $outputlangs Lang object for output language
* @return int 1=OK, 0=KO * @return int 1=OK, 0=KO
*/ */
function write_file($object,$outputlangs='') function write_file($object,$outputlangs='')

View File

@ -93,12 +93,12 @@ class InterfaceLogevents
* Function called when a Dolibarrr business event is done. * Function called when a Dolibarrr business event is done.
* All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers * All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers
* *
* @param action Code de l'evenement * @param string $action Event action code
* @param object Objet concerne * @param Object $object Object
* @param user Objet user * @param User $user Object user
* @param langs Objet langs * @param Translate $langs Object langs
* @param conf Objet conf * @param conf $conf Object conf
* @param entity Value for instance of data (Always 1 except if module MultiCompany is installed) * @param string $entity Value for instance of data (Always 1 except if module MultiCompany is installed)
* @return int <0 if KO, 0 if no triggered ran, >0 if OK * @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf,$entity=1) function run_trigger($action,$object,$user,$langs,$conf,$entity=1)

View File

@ -88,12 +88,12 @@ class InterfacePaypalWorkflow
* Fonction appelee lors du declenchement d'un evenement Dolibarr. * Fonction appelee lors du declenchement d'un evenement Dolibarr.
* D'autres fonctions run_trigger peuvent etre presentes dans core/triggers * D'autres fonctions run_trigger peuvent etre presentes dans core/triggers
* *
* @param string $action Code de l'evenement * @param string $action Event action code
* @param CommonObject $object Objet concerne * @param Object $object Object
* @param User $user Objet user * @param User $user Object user
* @param Translate $langs Objet lang * @param Translate $langs Object langs
* @param Conf $conf Objet conf * @param conf $conf Object conf
* @return int <0 if fatal error, 0 si nothing done, >0 if ok * @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf) function run_trigger($action,$object,$user,$langs,$conf)
{ {

View File

@ -90,12 +90,13 @@ class InterfaceWorkflowManager
* Function called when a Dolibarrr business event is done. * Function called when a Dolibarrr business event is done.
* All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers * All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers
* *
* @param action Event code (COMPANY_CREATE, PROPAL_VALIDATE, ...) * @param string $action Event action code
* @param object Object action is done on * @param Object $object Object
* @param user Object user * @param User $user Object user
* @param langs Object langs * @param Translate $langs Object langs
* @param conf Object conf * @param conf $conf Object conf
* @return int <0 if KO, 0 if no action are done, >0 if OK * @param string $entity Value for instance of data (Always 1 except if module MultiCompany is installed)
* @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf) function run_trigger($action,$object,$user,$langs,$conf)
{ {

View File

@ -104,12 +104,12 @@ class InterfaceActionsAuto
* $object->fk_element * $object->fk_element
* $object->elementtype * $object->elementtype
* *
* @param action Event code (COMPANY_CREATE, PROPAL_VALIDATE, ...) * @param string $action Event action code
* @param object Object action is done on * @param Object $object Object
* @param user Object user * @param User $user Object user
* @param langs Object langs * @param Translate $langs Object langs
* @param conf Object conf * @param conf $conf Object conf
* @return int <0 if KO, 0 if no action are done, >0 if OK * @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf) function run_trigger($action,$object,$user,$langs,$conf)
{ {

View File

@ -89,12 +89,12 @@ class InterfaceLdapsynchro
* Function called when a Dolibarrr business event is done. * Function called when a Dolibarrr business event is done.
* All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers * All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers
* *
* @param action Event code (COMPANY_CREATE, PROPAL_VALIDATE, ...) * @param string $action Event action code
* @param object Object action is done on * @param Object $object Object
* @param user Object user * @param User $user Object user
* @param langs Object langs * @param Translate $langs Object langs
* @param conf Object conf * @param conf $conf Object conf
* @return int <0 if KO, 0 if no action are done, >0 if OK * @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf) function run_trigger($action,$object,$user,$langs,$conf)
{ {

View File

@ -89,12 +89,12 @@ class InterfaceNotification
* Function called when a Dolibarrr business event is done. * Function called when a Dolibarrr business event is done.
* All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers * All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers
* *
* @param action Event code (COMPANY_CREATE, PROPAL_VALIDATE, ...) * @param string $action Event action code
* @param object Object action is done on * @param Object $object Object
* @param user Object user * @param User $user Object user
* @param langs Object langs * @param Translate $langs Object langs
* @param conf Object conf * @param conf $conf Object conf
* @return int <0 if KO, 0 if no action are done, >0 if OK * @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf) function run_trigger($action,$object,$user,$langs,$conf)
{ {

View File

@ -92,11 +92,12 @@ class InterfaceDemo
/** /**
* Function called when a Dolibarrr business event is done. * Function called when a Dolibarrr business event is done.
* All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers * All functions "run_trigger" are triggered if file is inside directory htdocs/core/triggers
* @param action Code de l'evenement *
* @param object Objet concerne * @param string $action Event action code
* @param user Objet user * @param Object $object Object
* @param langs Objet langs * @param User $user Object user
* @param conf Objet conf * @param Translate $langs Object langs
* @param conf $conf Object conf
* @return int <0 if KO, 0 if no triggered ran, >0 if OK * @return int <0 if KO, 0 if no triggered ran, >0 if OK
*/ */
function run_trigger($action,$object,$user,$langs,$conf) function run_trigger($action,$object,$user,$langs,$conf)

View File

@ -806,6 +806,7 @@ function migrate_contracts_det($db,$langs,$conf)
} }
/** /**
* Function to migrate links into llx_bank_url
* *
* @param DoliDB $db Database handler * @param DoliDB $db Database handler
* @param Translate $langs Object langs * @param Translate $langs Object langs
@ -2690,6 +2691,11 @@ function migrate_project_task_actors($db,$langs,$conf)
* @param DoliDB $db Database handler * @param DoliDB $db Database handler
* @param Translate $langs Object langs * @param Translate $langs Object langs
* @param Conf $conf Object conf * @param Conf $conf Object conf
* @param string $table Table name
* @param int $fk_source Id of element source
* @param type $sourcetype Type of element source
* @param int $fk_target Id of element target
* @param type $targettype Type of element target
* @return void * @return void
*/ */
function migrate_relationship_tables($db,$langs,$conf,$table,$fk_source,$sourcetype,$fk_target,$targettype) function migrate_relationship_tables($db,$langs,$conf,$table,$fk_source,$sourcetype,$fk_target,$targettype)

View File

@ -765,6 +765,8 @@ function deformatNVP($nvpstr)
/** /**
* Get API errors * Get API errors
*
* @return array Array of errors
*/ */
function getApiError() function getApiError()
{ {

View File

@ -50,27 +50,6 @@ if (isset($_SERVER["DOCUMENT_URI"]) && $_SERVER["DOCUMENT_URI"])
} }
// Define syslog constants
if (! defined('LOG_DEBUG'))
{
if (function_exists("define_syslog_variables"))
{
define_syslog_variables(); // Deprecated since php 5.3.0, syslog variables no longer need to be initialized
}
else
{
// Pour PHP sans syslog (comme sous Windows)
define('LOG_EMERG',0);
define('LOG_ALERT',1);
define('LOG_CRIT',2);
define('LOG_ERR',3);
define('LOG_WARNING',4);
define('LOG_NOTICE',5);
define('LOG_INFO',6);
define('LOG_DEBUG',7);
}
}
$includeconferror=''; $includeconferror='';
// Define vars // Define vars
@ -135,28 +114,6 @@ if (empty($conf->db->dolibarr_main_db_cryptkey)) $conf->db->dolibarr_main_db_c
if (empty($conf->db->user)) $conf->db->user=''; if (empty($conf->db->user)) $conf->db->user='';
// Removed magic_quotes
if (function_exists('get_magic_quotes_gpc')) // magic_quotes_* removed in PHP6
{
if (get_magic_quotes_gpc())
{
// Forcing parameter setting magic_quotes_gpc and cleaning parameters
// (Otherwise he would have for each position, condition
// Reading stripslashes variable according to state get_magic_quotes_gpc).
// Off mode (recommended, you just do $db->escape when an insert / update.
function stripslashes_deep($value)
{
return (is_array($value) ? array_map('stripslashes_deep', $value) : stripslashes($value));
}
$_GET = array_map('stripslashes_deep', $_GET);
$_POST = array_map('stripslashes_deep', $_POST);
$_COOKIE = array_map('stripslashes_deep', $_COOKIE);
$_REQUEST = array_map('stripslashes_deep', $_REQUEST);
@set_magic_quotes_runtime(0);
}
}
// Defini objet langs // Defini objet langs
$langs = new Translate('..',$conf); $langs = new Translate('..',$conf);
if (GETPOST('lang')) $langs->setDefaultLang(GETPOST('lang')); if (GETPOST('lang')) $langs->setDefaultLang(GETPOST('lang'));
@ -257,16 +214,4 @@ function pFooter($nonext=0,$setuplang='')
print '</html>'."\n"; print '</html>'."\n";
} }
/**
* Output a text into a log file
*
* @param string $message Message to show
* @param string $level Log level
*/
function dolibarr_support_syslog($message, $level=LOG_DEBUG)
{
if (! defined('LOG_DEBUG')) define('LOG_DEBUG',6);
dol_syslog($message,$level);
}
?> ?>

View File

@ -154,7 +154,7 @@ print '</td></tr></table>';
print '</td>'; print '</td>';
print '</tr><tr>'; print '</tr><tr>';
$urlwiki='http://wiki.dolibarr.org/index.php/List_of_OpenSource_Software_companies_and_freelancers'; $urlwiki='http://wiki.dolibarr.org/index.php/List of Dolibarr partners and providers';
print '<td align="center" valign="top">'; print '<td align="center" valign="top">';
print '<table class="nocellnopadd">'; print '<table class="nocellnopadd">';
/*print '<tr><td align="center" valign="top">'; /*print '<tr><td align="center" valign="top">';
@ -190,7 +190,7 @@ print '</td></tr></table>';
print '</td>'; print '</td>';
print '</tr><tr>'; print '</tr><tr>';
$urlwiki='http://wiki.dolibarr.org/index.php/List_of_OpenSource_Software_companies_and_freelancers'; $urlwiki='http://wiki.dolibarr.org/index.php/List of Dolibarr partners and providers';
print '<td align="center" valign="top">'; print '<td align="center" valign="top">';
print '<table class="nocellnopadd">'; print '<table class="nocellnopadd">';
/*print '<tr><td align="center" valign="top">'; /*print '<tr><td align="center" valign="top">';