diff --git a/htdocs/admin/stock.php b/htdocs/admin/stock.php index c8204f213c2..164e4fd6bc8 100644 --- a/htdocs/admin/stock.php +++ b/htdocs/admin/stock.php @@ -3,7 +3,7 @@ * Copyright (C) 2008-2010 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2012-2013 Juanjo Menent - * Copyright (C) 2013 Philippe Grand + * Copyright (C) 2013-2017 Philippe Grand * Copyright (C) 2013 Florian Henry * * This program is free software; you can redistribute it and/or modify @@ -435,7 +435,6 @@ if ($virtualdiffersfromphysical) print '
'; if ($conf->global->MAIN_LEVEL_FEATURES >= 2) { - $var=false; print ''; print ''; print ''."\n"; @@ -443,8 +442,7 @@ if ($conf->global->MAIN_LEVEL_FEATURES >= 2) print ''."\n"; // Example with a yes / no select - $var=!$var; - print ''; + print ''; print ''; print ''; print ''; // Example with a yes / no select - $var=!$var; - print ''; + print ''; print ''; print ''; print ''; // Example with a yes / no select - $var=!$var; - print ''; + print ''; print ''; print ''; print '
'.$langs->trans("Inventory").' 
'.$langs->trans("INVENTORY_DISABLE_VIRTUAL").' '; @@ -457,8 +455,7 @@ if ($conf->global->MAIN_LEVEL_FEATURES >= 2) print '
'.$langs->trans("INVENTORY_USE_MIN_PA_IF_NO_LAST_PA").' '; @@ -471,8 +468,7 @@ if ($conf->global->MAIN_LEVEL_FEATURES >= 2) print '
'.$langs->trans("INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT").' '; @@ -487,7 +483,6 @@ if ($conf->global->MAIN_LEVEL_FEATURES >= 2) print '
'; } -$var=true; print ''; print ''; @@ -509,8 +504,6 @@ if (! empty($conf->fournisseur->enabled) && !empty($conf->global->STOCK_CALCULAT print "\n\n"; } - - print ''; print ''; print '\n"; print "\n"; - - print ''; print ''; diff --git a/htdocs/categories/index.php b/htdocs/categories/index.php index ca2b7b5c76f..b68da6fd597 100644 --- a/htdocs/categories/index.php +++ b/htdocs/categories/index.php @@ -112,8 +112,7 @@ if ($catname || $id > 0) $var=true; foreach ($cats as $cat) { - $var = ! $var; - print "\t\n"; + print "\t".''."\n"; print "\t\t\n"; if (count($cats) > 0) { - $var=true; foreach ($cats as $cat) - { - - print "\t\n"; + { + print "\t".''."\n"; print "\t\t".'\n"; @@ -360,11 +358,9 @@ if ($object->type == Categorie::TYPE_PRODUCT) if (count($prods) > 0) { - $var=true; foreach ($prods as $prod) - { - - print "\t\n"; + { + print "\t".''."\n"; print '\n"; @@ -411,12 +407,9 @@ if ($object->type == Categorie::TYPE_SUPPLIER) if (count($socs) > 0) { - $var=true; foreach ($socs as $soc) - { - - print "\t\n"; - + { + print "\t".''."\n"; print '\n"; @@ -464,14 +457,13 @@ if($object->type == Categorie::TYPE_CUSTOMER) if (count($socs) > 0) { $i = 0; - $var=true; foreach ($socs as $key => $soc) { if ($user->societe_id > 0 && $soc->id != $user->societe_id) continue; // External user always see only themself $i++; - print "\t\n"; + print "\t".''."\n"; print '\n"; @@ -520,11 +512,9 @@ if ($object->type == Categorie::TYPE_MEMBER) if (count($prods) > 0) { - $var=true; foreach ($prods as $key => $member) - { - - print "\t\n"; + { + print "\t".''."\n"; print '\n"; + print "\t".''."\n"; print '\n"; @@ -629,11 +618,9 @@ if ($object->type == Categorie::TYPE_ACCOUNT) if (count($accounts) > 0) { - $var=true; foreach ($accounts as $key => $account) - { - - print "\t\n"; + { + print "\t".''."\n"; print '\n"; @@ -684,11 +671,9 @@ if ($object->type == Categorie::TYPE_PROJECT) if (count($projects) > 0) { - $var=true; foreach ($projects as $key => $project) - { - - print "\t\n"; + { + print "\t".''."\n"; print '\n"; diff --git a/htdocs/comm/card.php b/htdocs/comm/card.php index aae1398109d..b933289be4f 100644 --- a/htdocs/comm/card.php +++ b/htdocs/comm/card.php @@ -788,8 +788,7 @@ if ($id > 0) while ($i < $num && $i < $MAXLIST) { $objp = $db->fetch_object($resql); - $var = ! $var; - print ""; + print ''; print '"; + print ''; print '
'.$langs->trans("UserWarehouseAutoCreate").''; @@ -523,8 +516,6 @@ print ''; print "
'.$langs->trans("AllowAddLimitStockByWarehouse").'
"; $categstatic->id=$cat->id; $categstatic->ref=$cat->label; diff --git a/htdocs/categories/viewcat.php b/htdocs/categories/viewcat.php index ebd5fa9991c..d04d0baebd2 100644 --- a/htdocs/categories/viewcat.php +++ b/htdocs/categories/viewcat.php @@ -289,11 +289,9 @@ else print "
'; print "".$cat->label.""; print "
'; print $prod->getNomUrl(1); print "
'; print $soc->getNomUrl(1); print "
'; print $soc->getNomUrl(1); print "
'; $member->ref=$member->login; print $member->getNomUrl(1,0); @@ -574,12 +564,11 @@ if($object->type == Categorie::TYPE_CONTACT) if (count($contacts) > 0) { $i = 0; - $var=true; foreach ($contacts as $key => $contact) { $i++; - print "\t
'; print $contact->getNomUrl(1,'category'); print "
'; print $account->getNomUrl(1,0); print "
'; print $project->getNomUrl(1,0); print "
'; $sendingstatic->id = $objp->id; $sendingstatic->ref = $objp->ref; diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index 4bd999b1d5a..24bccbf9c9c 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -2,7 +2,7 @@ /* Copyright (C) 2001-2005 Rodolphe Quiedeville * Copyright (C) 2004-2015 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin - * Copyright (C) 2015 Jean-François Ferry + * Copyright (C) 2015 Jean-François Ferry * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -479,7 +479,6 @@ if (! empty($conf->societe->enabled) && $user->rights->societe->lire) $resql = $db->query($sql); if ($resql) { - $var=false; $num = $db->num_rows($resql); $i = 0; @@ -544,7 +543,6 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->societe->lire) $result = $db->query($sql); if ($result) { - $var=false; $num = $db->num_rows($result); $i = 0; @@ -633,11 +631,10 @@ if (! empty($conf->contrat->enabled) && $user->rights->contrat->lire && 0) // TO $staticcontrat=new Contrat($db); - $var=false; while ($i < $num) { $obj = $db->fetch_object($resql); - print "
contratid."\">".img_object($langs->trans("ShowContract","contract"), 'contract')." ".$obj->ref."
contratid."\">".img_object($langs->trans("ShowContract","contract"), "contract")." ".$obj->ref."'; $companystatic->id=$objp->rowid; $companystatic->name=$objp->name; @@ -686,8 +683,6 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) $i = 0; if ($num > 0) { - $var=true; - print ''; print ''; @@ -785,8 +780,6 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) $i = 0; if ($num > 0) { - $var=true; - print '
'.$langs->trans("ProposalsOpened").' '.$num.'
'; print ''; diff --git a/htdocs/comm/propal/stats/index.php b/htdocs/comm/propal/stats/index.php index abb24b8ffa4..5c74c8374a0 100644 --- a/htdocs/comm/propal/stats/index.php +++ b/htdocs/comm/propal/stats/index.php @@ -293,7 +293,6 @@ print ''; print ''; $oldyear=0; -$var=true; foreach ($data as $val) { $year = $val['year']; @@ -301,7 +300,7 @@ foreach ($data as $val) { // If we have empty year $oldyear--; - print ''; + print ''; print ''; print ''; print ''; @@ -311,7 +310,7 @@ foreach ($data as $val) print ''; print ''; } - print ''; + print ''; print ''; print ''; print '';
'.$langs->trans("OrdersOpened").' '.$num.'
%
0?'&userid='.$userid:'').'">'.$oldyear.'0
0?'&userid='.$userid:'').'">'.$year.''.$val['nb'].''.round($val['nb_diff']).'