diff --git a/htdocs/adherents/cotisations.php b/htdocs/adherents/cotisations.php index ff1c138aaa9..e3859931a38 100644 --- a/htdocs/adherents/cotisations.php +++ b/htdocs/adherents/cotisations.php @@ -52,10 +52,10 @@ if ($action == 'add') { } // Insertion de la cotisation dans le compte banquaire -if ($HTTP_POST_VARS["action"] == '2bank' && $HTTP_POST_VARS["rowid"] !=''){ +if ($_POST["action"] == '2bank' && $_POST["rowid"] !=''){ if (defined("ADHERENT_BANK_USE") && ADHERENT_BANK_USE !=0){ $dateop=strftime("%Y%m%d",time()); - $sql="SELECT cotisation FROM ".MAIN_DB_PREFIX."cotisation WHERE rowid=".$HTTP_POST_VARS["rowid"]." "; + $sql="SELECT cotisation FROM ".MAIN_DB_PREFIX."cotisation WHERE rowid=".$_POST["rowid"]." "; $result = $db->query($sql); if ($result) { @@ -65,7 +65,7 @@ if ($HTTP_POST_VARS["action"] == '2bank' && $HTTP_POST_VARS["rowid"] !=''){ $objp = $db->fetch_object(0); $amount=$objp->cotisation; $acct=new Account($db,ADHERENT_BANK_ACCOUNT); - $insertid=$acct->addline($dateop, $HTTP_POST_VARS["operation"], $HTTP_POST_VARS["label"], $amount, $HTTP_POST_VARS["num_chq"],ADHERENT_BANK_CATEGORIE); + $insertid=$acct->addline($dateop, $_POST["operation"], $_POST["label"], $amount, $_POST["num_chq"],ADHERENT_BANK_CATEGORIE); if ($insertid == '') { print "
Probleme d'insertion : ".$db->error(); @@ -73,7 +73,7 @@ if ($HTTP_POST_VARS["action"] == '2bank' && $HTTP_POST_VARS["rowid"] !=''){ else { // met a jour la table cotisation - $sql="UPDATE ".MAIN_DB_PREFIX."cotisation SET fk_bank=$insertid WHERE rowid=".$HTTP_POST_VARS["rowid"]." "; + $sql="UPDATE ".MAIN_DB_PREFIX."cotisation SET fk_bank=$insertid WHERE rowid=".$_POST["rowid"]." "; $result = $db->query($sql); if ($result) { diff --git a/htdocs/admin/ldap.php b/htdocs/admin/ldap.php index 81c2a5ed9d0..ad5d38da0ca 100644 --- a/htdocs/admin/ldap.php +++ b/htdocs/admin/ldap.php @@ -41,29 +41,29 @@ if ($_GET["action"] == 'setvalue' && $user->admin) $sql = "delete from ".MAIN_DB_PREFIX."const where name = 'LDAP_SERVER_HOST';"; $db->query($sql);$sql=''; $sql = "insert into ".MAIN_DB_PREFIX."const (name,value,visible) VALUES - ('LDAP_SERVER_HOST','".$HTTP_POST_VARS["host"]."',0);"; - //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_HOST', value='".$HTTP_POST_VARS["host"]."', visible=0"; + ('LDAP_SERVER_HOST','".$_POST["host"]."',0);"; + //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_HOST', value='".$_POST["host"]."', visible=0"; $db->query($sql); - //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_DN', value='".$HTTP_POST_VARS["dn"]."', visible=0"; + //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_DN', value='".$_POST["dn"]."', visible=0"; $sql = "delete from ".MAIN_DB_PREFIX."const where name = 'LDAP_SERVER_DN';"; $db->query($sql);$sql=''; $sql = "insert into ".MAIN_DB_PREFIX."const (name,value,visible) VALUES - ('LDAP_SERVER_DN','".$HTTP_POST_VARS["dn"]."',0);"; + ('LDAP_SERVER_DN','".$_POST["dn"]."',0);"; $db->query($sql); $sql = "delete from ".MAIN_DB_PREFIX."const where name = 'LDAP_SERVER_PASS';"; $db->query($sql);$sql=''; $sql = "insert into ".MAIN_DB_PREFIX."const (name,value,visible) VALUES - ('LDAP_SERVER_PASS','".$HTTP_POST_VARS["pass"]."',0);"; - //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_PASS', value='".$HTTP_POST_VARS["pass"]."', visible=0"; + ('LDAP_SERVER_PASS','".$_POST["pass"]."',0);"; + //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_PASS', value='".$_POST["pass"]."', visible=0"; $db->query($sql); - //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_TYPE', value='".$HTTP_POST_VARS["type"]."', visible=0"; + //$sql = "REPLACE INTO ".MAIN_DB_PREFIX."const SET name = 'LDAP_SERVER_TYPE', value='".$_POST["type"]."', visible=0"; $sql = "delete from ".MAIN_DB_PREFIX."const where name = 'LDAP_SERVER_TYPE';"; $db->query($sql);$sql=''; $sql = "insert into ".MAIN_DB_PREFIX."const (name,value,visible) VALUES - ('LDAP_SERVER_TYPE','".$HTTP_POST_VARS["type"]."',0);"; + ('LDAP_SERVER_TYPE','".$_POST["type"]."',0);"; $db->query($sql); diff --git a/htdocs/admin/system/gen-commande.php b/htdocs/admin/system/gen-commande.php index 116f4286cf6..1c886752c81 100644 --- a/htdocs/admin/system/gen-commande.php +++ b/htdocs/admin/system/gen-commande.php @@ -73,7 +73,7 @@ $com = new Commande($db); $com->soc_id = 4; $com->date_commande = $dates[rand(1, sizeof($dates)-1)]; -$com->note = $HTTP_POST_VARS["note"]; +$com->note = $_POST["note"]; $com->source = 1; $com->projetid = 0; $com->remise_percent = 0; diff --git a/htdocs/admin/system/gendata.php b/htdocs/admin/system/gendata.php index 866bbc0cedc..fda3abc4a06 100644 --- a/htdocs/admin/system/gendata.php +++ b/htdocs/admin/system/gendata.php @@ -249,7 +249,7 @@ if ($_GET["action"] == 'commande') $com->soc_id = 4; $com->date_commande = $dates[rand(1, sizeof($dates)-1)]; - $com->note = $HTTP_POST_VARS["note"]; + $com->note = $_POST["note"]; $com->source = 1; $com->projetid = 0; $com->remise_percent = 0; diff --git a/htdocs/boutique/auteur/fiche.php b/htdocs/boutique/auteur/fiche.php index 44e0d0a9b5b..09a79a68ebf 100644 --- a/htdocs/boutique/auteur/fiche.php +++ b/htdocs/boutique/auteur/fiche.php @@ -37,7 +37,7 @@ if ($action == 'addga') { $auteur->linkga($id, $ga); } -if ($HTTP_POST_VARS["action"] == 'confirm_delete' && $HTTP_POST_VARS["confirm"] == yes) +if ($_POST["action"] == 'confirm_delete' && $_POST["confirm"] == yes) { $auteur = new Auteur($db); $result = $auteur->fetch($id); diff --git a/htdocs/boutique/editeur/fiche.php b/htdocs/boutique/editeur/fiche.php index de1df3b50e4..23e54b88812 100644 --- a/htdocs/boutique/editeur/fiche.php +++ b/htdocs/boutique/editeur/fiche.php @@ -46,7 +46,7 @@ if ($action == 'update' && !$cancel) $editeur->update($id, $user); } -if ($HTTP_POST_VARS["action"] == 'confirm_delete' && $HTTP_POST_VARS["confirm"] == yes) +if ($_POST["action"] == 'confirm_delete' && $_POST["confirm"] == yes) { $editeur = new Editeur($db); $result = $editeur->fetch($id); diff --git a/htdocs/boutique/livre/fiche.php b/htdocs/boutique/livre/fiche.php index b79119a4109..e461f6b29db 100644 --- a/htdocs/boutique/livre/fiche.php +++ b/htdocs/boutique/livre/fiche.php @@ -23,7 +23,7 @@ require("./pre.inc.php"); -if ( $HTTP_POST_VARS["sendit"] ) +if ( $_POST["sendit"] ) { global $local_file, $error_msg; @@ -70,7 +70,7 @@ if ($action == 'add') $livre->annee = $annee; $livre->editeurid = $editeurid; $livre->description = $desc; - $livre->frais_de_port = $HTTP_POST_VARS["fdp"]; + $livre->frais_de_port = $_POST["fdp"]; $id = $livre->create($user); } @@ -81,7 +81,7 @@ if ($action == 'addga') $livre->linkga($id, $coauteurid); } -if ($HTTP_POST_VARS["action"] == 'confirm_delete' && $HTTP_POST_VARS["confirm"] == "yes") +if ($_POST["action"] == 'confirm_delete' && $_POST["confirm"] == "yes") { $livre = new Livre($db); $livre->fetch($id); @@ -128,7 +128,7 @@ if ($action == 'update' && !$cancel) $livre->titre = $titre; $livre->ref = $ref; $livre->price = $price; - $livre->frais_de_port = $HTTP_POST_VARS["fdp"]; + $livre->frais_de_port = $_POST["fdp"]; $livre->annee = $annee; $livre->editeurid = $editeurid; $livre->description = $desc; diff --git a/htdocs/boutique/newsletter/fiche.php b/htdocs/boutique/newsletter/fiche.php index a7b34149c61..a21e8c47fae 100644 --- a/htdocs/boutique/newsletter/fiche.php +++ b/htdocs/boutique/newsletter/fiche.php @@ -26,11 +26,11 @@ require("./pre.inc.php"); if ($action == 'add') { $newsletter = new Newsletter($db); - $newsletter->email_subject = $HTTP_POST_VARS["email_subject"]; - $newsletter->email_from_name = $HTTP_POST_VARS["email_from_name"]; - $newsletter->email_from_email = $HTTP_POST_VARS["email_from_email"]; - $newsletter->email_replyto = $HTTP_POST_VARS["email_replyto"]; - $newsletter->email_body = $HTTP_POST_VARS["email_body"]; + $newsletter->email_subject = $_POST["email_subject"]; + $newsletter->email_from_name = $_POST["email_from_name"]; + $newsletter->email_from_email = $_POST["email_from_email"]; + $newsletter->email_replyto = $_POST["email_replyto"]; + $newsletter->email_body = $_POST["email_body"]; $id = $newsletter->create($user); } @@ -45,16 +45,16 @@ if ($action == 'update' && !$cancel) { $newsletter = new Newsletter($db); - $newsletter->email_subject = $HTTP_POST_VARS["email_subject"]; - $newsletter->email_from_name = $HTTP_POST_VARS["email_from_name"]; - $newsletter->email_from_email = $HTTP_POST_VARS["email_from_email"]; - $newsletter->email_replyto = $HTTP_POST_VARS["email_replyto"]; - $newsletter->email_body = $HTTP_POST_VARS["email_body"]; + $newsletter->email_subject = $_POST["email_subject"]; + $newsletter->email_from_name = $_POST["email_from_name"]; + $newsletter->email_from_email = $_POST["email_from_email"]; + $newsletter->email_replyto = $_POST["email_replyto"]; + $newsletter->email_body = $_POST["email_body"]; $newsletter->update($id, $user); } -if ($HTTP_POST_VARS["action"] == 'confirm_delete' && $HTTP_POST_VARS["confirm"] == yes) +if ($_POST["action"] == 'confirm_delete' && $_POST["confirm"] == yes) { $newsletter = new Newsletter($db); $result = $newsletter->fetch($id); @@ -62,14 +62,14 @@ if ($HTTP_POST_VARS["action"] == 'confirm_delete' && $HTTP_POST_VARS["confirm"] Header("Location: index.php"); } -if ($HTTP_POST_VARS["action"] == 'confirm_valid' && $HTTP_POST_VARS["confirm"] == yes) +if ($_POST["action"] == 'confirm_valid' && $_POST["confirm"] == yes) { $newsletter = new Newsletter($db); $result = $newsletter->fetch($id); $newsletter->validate($user); } -if ($HTTP_POST_VARS["action"] == 'confirm_send' && $HTTP_POST_VARS["confirm"] == yes) +if ($_POST["action"] == 'confirm_send' && $_POST["confirm"] == yes) { $newsletter = new Newsletter($db); $result = $newsletter->fetch($id); diff --git a/htdocs/comm/propal/document.php b/htdocs/comm/propal/document.php index ec535b6c98c..7d074b294d3 100644 --- a/htdocs/comm/propal/document.php +++ b/htdocs/comm/propal/document.php @@ -77,7 +77,7 @@ if ($id > 0) dol_delete_file($file); } - if ( $HTTP_POST_VARS["sendit"] ) + if ( $_POST["sendit"] ) { do_upload ($upload_dir); } diff --git a/htdocs/compta/dons/edit.php b/htdocs/compta/dons/edit.php index 3487df45732..39207031fd1 100644 --- a/htdocs/compta/dons/edit.php +++ b/htdocs/compta/dons/edit.php @@ -31,10 +31,10 @@ if ($action == 'update') $don = new Don($db); - $don->id = $HTTP_POST_VARS["rowid"]; + $don->id = $_POST["rowid"]; $don->prenom = $prenom; $don->nom = $nom; - $don->statut = $HTTP_POST_VARS["statutid"]; + $don->statut = $_POST["statutid"]; $don->societe = $societe; $don->adresse = $adresse; $don->amount = $amount; @@ -46,7 +46,7 @@ if ($action == 'update') $don->pays = $pays; $don->public = $public; $don->projetid = $projetid; - $don->commentaire = $HTTP_POST_VARS["comment"]; + $don->commentaire = $_POST["comment"]; $don->modepaiementid = $modepaiement; if ($don->update($user->id) ) diff --git a/htdocs/compta/dons/fiche.php b/htdocs/compta/dons/fiche.php index 6dd608896ad..22771c27413 100644 --- a/htdocs/compta/dons/fiche.php +++ b/htdocs/compta/dons/fiche.php @@ -45,7 +45,7 @@ if ($action == 'add') $don->pays = $pays; $don->public = $public; $don->projetid = $projetid; - $don->commentaire = $HTTP_POST_VARS["comment"]; + $don->commentaire = $_POST["comment"]; $don->modepaiementid = $modepaiement; if ($don->create($user->id) ) @@ -69,7 +69,7 @@ if ($action == 'delete') if ($action == 'commentaire') { $don = new Don($db); - $don->set_commentaire($rowid,$HTTP_POST_VARS["commentaire"]); + $don->set_commentaire($rowid,$_POST["commentaire"]); $action = "edit"; } if ($action == 'valid_promesse') diff --git a/htdocs/compta/facture/fiche-rec.php b/htdocs/compta/facture/fiche-rec.php index 498225a3f2a..07cd37f6682 100644 --- a/htdocs/compta/facture/fiche-rec.php +++ b/htdocs/compta/facture/fiche-rec.php @@ -50,11 +50,11 @@ if ($user->societe_id > 0) /* * */ -if ($HTTP_POST_VARS["action"] == 'add') +if ($_POST["action"] == 'add') { $facturerec = new FactureRec($db, $facid); - $facturerec->titre = $HTTP_POST_VARS["titre"]; + $facturerec->titre = $_POST["titre"]; if ($facturerec->create($user) > 0) { diff --git a/htdocs/expedition/commande.php b/htdocs/expedition/commande.php index 4a8b4ba976a..916810e5ba1 100644 --- a/htdocs/expedition/commande.php +++ b/htdocs/expedition/commande.php @@ -47,7 +47,7 @@ if ($user->societe_id > 0) * */ -if ($HTTP_POST_VARS["action"] == 'confirm_cloture' && $HTTP_POST_VARS["confirm"] == yes) +if ($_POST["action"] == 'confirm_cloture' && $_POST["confirm"] == yes) { $commande = new Commande($db); $commande->fetch($_GET["id"]); diff --git a/htdocs/expedition/liste.php b/htdocs/expedition/liste.php index 30b4a2640c1..dd531115dc4 100644 --- a/htdocs/expedition/liste.php +++ b/htdocs/expedition/liste.php @@ -70,9 +70,9 @@ if ($socidp) $sql_add = " AND "; } -if (strlen($HTTP_POST_VARS["sf_ref"]) > 0) +if (strlen($_POST["sf_ref"]) > 0) { - $sql .= $sql_add . " e.ref like '%".$HTTP_POST_VARS["sf_ref"] . "%'"; + $sql .= $sql_add . " e.ref like '%".$_POST["sf_ref"] . "%'"; } $expedition = new Expedition($db); diff --git a/htdocs/fourn/facture/paiement.php b/htdocs/fourn/facture/paiement.php index 309e4854417..e8c94dcfb92 100644 --- a/htdocs/fourn/facture/paiement.php +++ b/htdocs/fourn/facture/paiement.php @@ -41,9 +41,9 @@ if ($action == 'add') { $paiementfourn->facid = $facid; $paiementfourn->facnumber = $facnumber; $paiementfourn->datepaye = $db->idate(mktime(12, 0 , 0, - $HTTP_POST_VARS["remonth"], - $HTTP_POST_VARS["reday"], - $HTTP_POST_VARS["reyear"])); + $_POST["remonth"], + $_POST["reday"], + $_POST["reyear"])); $paiementfourn->amount = $amount; $paiementfourn->accountid = $accountid; $paiementfourn->societe = $societe; diff --git a/htdocs/install/etape2.php b/htdocs/install/etape2.php index d7df7813ed9..540cf589414 100644 --- a/htdocs/install/etape2.php +++ b/htdocs/install/etape2.php @@ -45,7 +45,7 @@ else require ($dolibarr_main_document_root . "/conf/conf.class.php");// ne sert plus -if ($HTTP_POST_VARS["action"] == "set") +if ($_POST["action"] == "set") { print '