diff --git a/htdocs/compta/clients.php b/htdocs/compta/clients.php index aba6460d8e2..ceb9324961e 100644 --- a/htdocs/compta/clients.php +++ b/htdocs/compta/clients.php @@ -172,14 +172,10 @@ if ($resql) print ''; print "\n"; - $var=true; - while ($i < min($num,$conf->liste_limit)) { $obj = $db->fetch_object($resql); - - print ''; print ''; $thirdpartystatic->id=$obj->rowid; diff --git a/htdocs/compta/index.php b/htdocs/compta/index.php index 112b7479621..09a528b1ce7 100644 --- a/htdocs/compta/index.php +++ b/htdocs/compta/index.php @@ -568,10 +568,8 @@ if (! empty($conf->don->enabled) && $user->rights->societe->lire) print ''; if ($num) { - $var = true; $total_ttc = $totalam = $total = 0; - $var=true; while ($i < $num && $i < $max) { $objp = $db->fetch_object($result); @@ -632,7 +630,6 @@ if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) $resql = $db->query($sql); if ( $resql ) { - $var = false; $num = $db->num_rows($resql); print ''; @@ -664,7 +661,6 @@ if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) print ''; print ''; $tot_ttc+=$obj->amount; - $var = !$var; $i++; } @@ -722,7 +718,6 @@ if (! empty($conf->facture->enabled) && ! empty($conf->commande->enabled) && $us $resql = $db->query($sql); if ( $resql ) { - $var=false; $num = $db->num_rows($resql); if ($num) @@ -838,7 +833,6 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire) $resql = $db->query($sql); if ($resql) { - $var=false; $num = $db->num_rows($resql); $i = 0; @@ -972,7 +966,6 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- $resql=$db->query($sql); if ($resql) { - $var=false; $num = $db->num_rows($resql); print '
'; @@ -1023,7 +1016,6 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture- $total_ttc += $obj->total_ttc; $totalam += $obj->am; $i++; - $var = !$var; } print '
'; @@ -1057,7 +1049,6 @@ if ($resql) print '
'.$chargestatic->getLibStatut(3).'
'.$langs->trans("Total").'   ('.$langs->trans("RemainderToPay").': '.price($total_ttc-$totalam).')
'; print ''.$langs->trans("TasksToDo").''; print "\n"; - $var = true; $i = 0; while ($i < $db->num_rows($resql)) { diff --git a/htdocs/compta/paiement.php b/htdocs/compta/paiement.php index 6c9f8014e19..c2ce95dd827 100644 --- a/htdocs/compta/paiement.php +++ b/htdocs/compta/paiement.php @@ -589,7 +589,6 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie print ''; print "\n"; - $var=true; $total=0; $totalrecu=0; $totalrecucreditnote=0; @@ -599,7 +598,6 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie { $objp = $db->fetch_object($resql); - $soc = new Societe($db); $soc->fetch($objp->socid); @@ -842,7 +840,6 @@ if (! GETPOST('action','aZ09')) { $num = $db->num_rows($resql); $i = 0; - $var=true; print_barre_liste($langs->trans('Payments'), $page, $_SERVER["PHP_SELF"],'',$sortfield,$sortorder,'',$num); print '
 
'; diff --git a/htdocs/compta/paiement_charge.php b/htdocs/compta/paiement_charge.php index cadf897c57f..fba8723d818 100644 --- a/htdocs/compta/paiement_charge.php +++ b/htdocs/compta/paiement_charge.php @@ -272,7 +272,6 @@ if ($action == 'create') print ''; print "\n"; - $var=true; $total=0; $totalrecu=0; @@ -280,8 +279,6 @@ if ($action == 'create') { $objp = $charge; - - print ''; if ($objp->date_ech > 0) @@ -325,7 +322,7 @@ if ($action == 'create') if ($i > 1) { // Print total - print ""; + print ''; print ''; print ""; print ""; diff --git a/htdocs/compta/recap-compta.php b/htdocs/compta/recap-compta.php index b6e2ea26647..3a22666e2f7 100644 --- a/htdocs/compta/recap-compta.php +++ b/htdocs/compta/recap-compta.php @@ -129,7 +129,6 @@ if ($id > 0) $resql=$db->query($sql); if ($resql) { - $var=true; $num = $db->num_rows($resql); // Boucle sur chaque facture diff --git a/htdocs/compta/salaries/index.php b/htdocs/compta/salaries/index.php index 8b8d732e9b8..0b70275654f 100644 --- a/htdocs/compta/salaries/index.php +++ b/htdocs/compta/salaries/index.php @@ -140,7 +140,6 @@ if ($result) $num = $db->num_rows($result); $i = 0; $total = 0 ; - $var=true; $param=''; if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage; diff --git a/htdocs/compta/sociales/index.php b/htdocs/compta/sociales/index.php index c5f9cfcbead..bd323c972fe 100644 --- a/htdocs/compta/sociales/index.php +++ b/htdocs/compta/sociales/index.php @@ -137,7 +137,6 @@ if ($resql) { $num = $db->num_rows($resql); $i = 0; - $var=true; $param=''; if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage; diff --git a/htdocs/compta/sociales/payments.php b/htdocs/compta/sociales/payments.php index 379abd7af09..3b7f68f8c83 100644 --- a/htdocs/compta/sociales/payments.php +++ b/htdocs/compta/sociales/payments.php @@ -158,12 +158,10 @@ if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) $total = 0; $totalnb = 0; $totalpaye = 0; - $var=true; while ($i < min($num, $limit)) { $obj = $db->fetch_object($resql); - $var = !$var; print ''; // Ref payment $payment_sc_static->id=$obj->pid; @@ -253,14 +251,13 @@ if (! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) print_liste_field_titre("DatePayment",$_SERVER["PHP_SELF"],"pv.datev","",$param,'align="center"',$sortfield,$sortorder); print_liste_field_titre("PayedByThisPayment",$_SERVER["PHP_SELF"],"pv.amount","",$param,'align="right"',$sortfield,$sortorder); print "\n"; - $var=1; + while ($i < $num) { $obj = $db->fetch_object($result); $total = $total + $obj->amount; - print ''; print ''."\n"; @@ -355,14 +352,13 @@ while($j<$numlt) print_liste_field_titre("DatePayment",$_SERVER["PHP_SELF"],"pv.datep","",$param,'align="center"',$sortfield,$sortorder); print_liste_field_titre("PayedByThisPayment",$_SERVER["PHP_SELF"],"pv.amount","",$param,'align="right"',$sortfield,$sortorder); print "\n"; - $var=1; + while ($i < $num) { $obj = $db->fetch_object($result); $total = $total + $obj->amount; - print ''; print ''."\n"; @@ -437,14 +433,13 @@ if (! empty($conf->salaries->enabled) && $user->rights->salaries->read) print_liste_field_titre("DatePayment",$_SERVER["PHP_SELF"],"s.datep","",$param,'align="center"',$sortfield,$sortorder); print_liste_field_titre("PayedByThisPayment",$_SERVER["PHP_SELF"],"s.amount","",$param,'align="right"',$sortfield,$sortorder); print "\n"; - $var=1; + while ($i < $num) { $obj = $db->fetch_object($result); $total = $total + $obj->amount; - print ''; print ''."\n"; diff --git a/htdocs/compta/stats/cabyuser.php b/htdocs/compta/stats/cabyuser.php index 8b1e1f0f106..dbd5d46e61a 100644 --- a/htdocs/compta/stats/cabyuser.php +++ b/htdocs/compta/stats/cabyuser.php @@ -327,8 +327,7 @@ print_liste_field_titre( "", 'align="center" width="20%"' ); -print "\n"; -$var=true; +print "\n"; if (count($amount)) { $arrayforsort=$name; diff --git a/htdocs/compta/tva/list.php b/htdocs/compta/tva/list.php index 97932d7b1ba..d835b0264e1 100644 --- a/htdocs/compta/tva/list.php +++ b/htdocs/compta/tva/list.php @@ -141,7 +141,6 @@ if ($result) $num = $db->num_rows($result); $i = 0; $total = 0 ; - $var=true; $param=''; if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage; diff --git a/htdocs/contrat/services_list.php b/htdocs/contrat/services_list.php index c94be74b0b8..290226f815e 100644 --- a/htdocs/contrat/services_list.php +++ b/htdocs/contrat/services_list.php @@ -531,7 +531,6 @@ print "\n"; $contractstatic=new Contrat($db); $productstatic=new Product($db); -$var=true; $i=0; $totalarray=array(); while ($i < min($num,$limit)) diff --git a/htdocs/don/payment/payment.php b/htdocs/don/payment/payment.php index fe4197dbc15..d1cfaa6f0ad 100644 --- a/htdocs/don/payment/payment.php +++ b/htdocs/don/payment/payment.php @@ -249,7 +249,6 @@ if (GETPOST('action','aZ09') == 'create') print ''; print "\n"; - $var=true; $total=0; $totalrecu=0; @@ -257,8 +256,6 @@ if (GETPOST('action','aZ09') == 'create') { $objp = $don; - - print ''; print '"; @@ -288,7 +285,7 @@ if (GETPOST('action','aZ09') == 'create') if ($i > 1) { // Print total - print ""; + print ''; print ''; print ""; print ""; diff --git a/htdocs/expensereport/list.php b/htdocs/expensereport/list.php index 0caf115690d..5565512f7f5 100644 --- a/htdocs/expensereport/list.php +++ b/htdocs/expensereport/list.php @@ -644,7 +644,6 @@ if ($resql) if ($num > 0) { $i=0; - $var=true; $totalarray=array(); while ($i < min($num,$limit)) { diff --git a/htdocs/exports/class/export.class.php b/htdocs/exports/class/export.class.php index 8a662c83dcf..050318944d6 100644 --- a/htdocs/exports/class/export.class.php +++ b/htdocs/exports/class/export.class.php @@ -80,7 +80,6 @@ class Export dol_syslog(get_class($this)."::load_arrays user=".$user->id." filter=".$filter); - $var=true; $i=0; // Define list of modules directories into modulesdir @@ -595,8 +594,6 @@ class Export // Genere ligne de titre $objmodel->write_title($this->array_export_fields[$indice],$array_selected,$outputlangs,$this->array_export_TypeFields[$indice]); - $var=true; - while ($obj = $this->db->fetch_object($resql)) { // Process special operations diff --git a/htdocs/exports/export.php b/htdocs/exports/export.php index 0a0d225e750..6d65418be3c 100644 --- a/htdocs/exports/export.php +++ b/htdocs/exports/export.php @@ -585,12 +585,10 @@ if ($step == 2 && $datatoexport) // $this->array_export_entities[0]=$module->export_fields_entities[$r]; // $this->array_export_alias[0]=$module->export_fields_alias[$r]; - $var=true; $i = 0; foreach($fieldsarray as $code=>$label) { - print ''; $i++; @@ -779,7 +777,6 @@ if ($step == 3 && $datatoexport) // Select request if all fields are selected $sqlmaxforexport=$objexport->build_sql(0, array(), array()); - $var=true; $i = 0; // on boucle sur les champs foreach($fieldsarray as $code => $label) @@ -977,7 +974,6 @@ if ($step == 4 && $datatoexport) //print ''; print ''; - $var=true; foreach($array_selected as $code=>$value) { print ''; @@ -1074,7 +1070,7 @@ if ($step == 4 && $datatoexport) print ''; print ''; print ''; - $var=false; + print ''; print '
'.$langs->trans("Amount").'
'.$langs->trans("Total").':".price($total_ttc)."".price($totalrecu)."
'.dol_print_date($db->jdate($obj->dm),'day').'
'.dol_print_date($db->jdate($obj->dm),'day').'
'.dol_print_date($db->jdate($obj->dateep),'day').'
'.$langs->trans("Amount").'
'.price($objp->amount)."
'.$langs->trans("Total").':".price($total_ttc)."".price($totalrecu)."
'.$langs->trans("FieldsTitle").'
'.$langs->trans("ExportModelName").' 
'; print ''; @@ -1091,10 +1087,8 @@ if ($step == 4 && $datatoexport) { $num = $db->num_rows($resql); $i = 0; - $var=false; while ($i < $num) { - $obj = $db->fetch_object($resql); print '
'; print $obj->label; @@ -1229,8 +1223,7 @@ if ($step == 5 && $datatoexport) print $langs->trans("NowClickToGenerateToBuildExportFile").'
'; - // Liste des formats d'exports disponibles - $var=true; + // List of available export formats print ''; print ''; print ''; @@ -1248,7 +1241,6 @@ if ($step == 5 && $datatoexport) unset($liste[$key]); } - print ''; print ''; print ''; //print ''; print ''; -$var=true; if (count($export->array_export_code)) { foreach ($export->array_export_code as $key => $value) @@ -112,8 +111,7 @@ print '
'; //print '
'; -// List of available export format -$var=true; +// List of available export formats print '
'.$langs->trans("AvailableFormats").'
'.img_picto_common($key,$objmodelexport->getPictoForKey($key)).' '; $text=$objmodelexport->getDriverDescForKey($key); diff --git a/htdocs/exports/index.php b/htdocs/exports/index.php index 01a663dc484..b23d1ff6ab7 100644 --- a/htdocs/exports/index.php +++ b/htdocs/exports/index.php @@ -60,7 +60,6 @@ print ''.$langs->trans("Module").''.$langs->trans("ExportableDatas").' 
'; print ''; print ''; @@ -125,7 +123,6 @@ include_once DOL_DOCUMENT_ROOT.'/core/modules/export/modules_export.php'; $model=new ModeleExports($db); $liste=$model->liste_modeles($db); // This is not a static method for exports because method load non static properties -$var=true; foreach($liste as $key => $val) { if (preg_match('/__\(Disabled\)__/',$liste[$key])) @@ -133,7 +130,6 @@ foreach($liste as $key => $val) $liste[$key]=preg_replace('/__\(Disabled\)__/','('.$langs->transnoentitiesnoconv("Disabled").')',$liste[$key]); } - print ''; print ''; $text=$model->getDriverDescForKey($key);
'.$langs->trans("AvailableFormats").'
'.img_picto_common($model->getDriverLabelForKey($key),$model->getPictoForKey($key)).'