Completed
Branch develop (284048)
by
unknown
19:26
created
htdocs/projet/card.php 1 patch
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -36,9 +36,9 @@  discard block
 block discarded – undo
36 36
 require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php';
37 37
 
38 38
 // Load translation files required by the page
39
-$langsLoad=array('projects', 'companies');
39
+$langsLoad = array('projects', 'companies');
40 40
 if (isModEnabled('eventorganization')) {
41
-	$langsLoad[]='eventorganization';
41
+	$langsLoad[] = 'eventorganization';
42 42
 }
43 43
 
44 44
 $langs->loadLangs($langsLoad);
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
 
108 108
 $permissiontoadd = $user->hasRight('projet', 'creer');
109 109
 $permissiontodelete = $user->hasRight('projet', 'supprimer');
110
-$permissiondellink = $user->hasRight('projet', 'creer');	// Used by the include of actions_dellink.inc.php
110
+$permissiondellink = $user->hasRight('projet', 'creer'); // Used by the include of actions_dellink.inc.php
111 111
 
112 112
 
113 113
 /*
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
 		$action = '';
159 159
 	}
160 160
 
161
-	include DOL_DOCUMENT_ROOT.'/core/actions_dellink.inc.php';		// Must be include, not include_once
161
+	include DOL_DOCUMENT_ROOT.'/core/actions_dellink.inc.php'; // Must be include, not include_once
162 162
 
163 163
 	// Action setdraft object
164 164
 	if ($action == 'confirm_setdraft' && $confirm == 'yes' && $permissiontoadd) {
@@ -318,7 +318,7 @@  discard block
 block discarded – undo
318 318
 			$object->date_end_event   = (!GETPOST('date_end_event')) ? '' : $date_end_event;
319 319
 			$object->location     = $location;
320 320
 			if (GETPOSTISSET('opp_amount')) {
321
-				$object->opp_amount   = price2num(GETPOST('opp_amount', 'alpha'));
321
+				$object->opp_amount = price2num(GETPOST('opp_amount', 'alpha'));
322 322
 			}
323 323
 			if (GETPOSTISSET('budget_amount')) {
324 324
 				$object->budget_amount = price2num(GETPOST('budget_amount', 'alpha'));
@@ -470,7 +470,7 @@  discard block
 block discarded – undo
470 470
 			if (!empty($_SESSION['pageforbacktolist']) && !empty($_SESSION['pageforbacktolist']['project'])) {
471 471
 				$tmpurl = $_SESSION['pageforbacktolist']['project'];
472 472
 				$tmpurl = preg_replace('/__SOCID__/', $object->socid, $tmpurl);
473
-				$urlback = $tmpurl.(preg_match('/\?/', $tmpurl) ? '&' : '?'). 'restore_lastsearch_values=1';
473
+				$urlback = $tmpurl.(preg_match('/\?/', $tmpurl) ? '&' : '?').'restore_lastsearch_values=1';
474 474
 			} else {
475 475
 				$urlback = DOL_URL_ROOT.'/projet/list.php?restore_lastsearch_values=1';
476 476
 			}
@@ -1024,7 +1024,7 @@  discard block
 block discarded – undo
1024 1024
 				print '<br>';
1025 1025
 			}
1026 1026
 			if (!getDolGlobalString('PROJECT_HIDE_TASKS')) {
1027
-				print '<input type="checkbox" id="usage_task" name="usage_task"' . (GETPOSTISSET('usage_task') ? (GETPOST('usage_task', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_task ? ' checked="checked"' : '')) . '> ';
1027
+				print '<input type="checkbox" id="usage_task" name="usage_task"'.(GETPOSTISSET('usage_task') ? (GETPOST('usage_task', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_task ? ' checked="checked"' : '')).'> ';
1028 1028
 				$htmltext = $langs->trans("ProjectFollowTasks");
1029 1029
 				print '<label for="usage_task">'.$form->textwithpicto($langs->trans("ProjectFollowTasks"), $htmltext).'</label>';
1030 1030
 				print '<script>';
@@ -1050,7 +1050,7 @@  discard block
 block discarded – undo
1050 1050
 				print '<br>';
1051 1051
 			}
1052 1052
 			if (!getDolGlobalString('PROJECT_HIDE_TASKS') && getDolGlobalString('PROJECT_BILL_TIME_SPENT')) {
1053
-				print '<input type="checkbox" id="usage_bill_time" name="usage_bill_time"' . (GETPOSTISSET('usage_bill_time') ? (GETPOST('usage_bill_time', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_bill_time ? ' checked="checked"' : '')) . '> ';
1053
+				print '<input type="checkbox" id="usage_bill_time" name="usage_bill_time"'.(GETPOSTISSET('usage_bill_time') ? (GETPOST('usage_bill_time', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_bill_time ? ' checked="checked"' : '')).'> ';
1054 1054
 				$htmltext = $langs->trans("ProjectBillTimeDescription");
1055 1055
 				print '<label for="usage_bill_time">'.$form->textwithpicto($langs->trans("BillTime"), $htmltext).'</label>';
1056 1056
 				print '<script>';
@@ -1076,7 +1076,7 @@  discard block
 block discarded – undo
1076 1076
 				print '<br>';
1077 1077
 			}
1078 1078
 			if (isModEnabled('eventorganization')) {
1079
-				print '<input type="checkbox" id="usage_organize_event" name="usage_organize_event"'. (GETPOSTISSET('usage_organize_event') ? (GETPOST('usage_organize_event', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_organize_event ? ' checked="checked"' : '')) . '> ';
1079
+				print '<input type="checkbox" id="usage_organize_event" name="usage_organize_event"'.(GETPOSTISSET('usage_organize_event') ? (GETPOST('usage_organize_event', 'alpha') != '' ? ' checked="checked"' : '') : ($object->usage_organize_event ? ' checked="checked"' : '')).'> ';
1080 1080
 				$htmltext = $langs->trans("EventOrganizationDescriptionLong");
1081 1081
 				print '<label for="usage_organize_event">'.$form->textwithpicto($langs->trans("ManageOrganizeEvent"), $htmltext).'</label>';
1082 1082
 				print '<script>';
@@ -1254,7 +1254,7 @@  discard block
 block discarded – undo
1254 1254
 		if (!empty($_SESSION['pageforbacktolist']) && !empty($_SESSION['pageforbacktolist']['project'])) {
1255 1255
 			$tmpurl = $_SESSION['pageforbacktolist']['project'];
1256 1256
 			$tmpurl = preg_replace('/__SOCID__/', $object->socid, $tmpurl);
1257
-			$linkback = '<a href="'.$tmpurl.(preg_match('/\?/', $tmpurl) ? '&' : '?'). 'restore_lastsearch_values=1">'.$langs->trans("BackToList").'</a>';
1257
+			$linkback = '<a href="'.$tmpurl.(preg_match('/\?/', $tmpurl) ? '&' : '?').'restore_lastsearch_values=1">'.$langs->trans("BackToList").'</a>';
1258 1258
 		} else {
1259 1259
 			$linkback = '<a href="'.DOL_URL_ROOT.'/projet/list.php?restore_lastsearch_values=1">'.$langs->trans("BackToList").'</a>';
1260 1260
 		}
@@ -1556,7 +1556,7 @@  discard block
 block discarded – undo
1556 1556
 					if ($userWrite > 0) {
1557 1557
 						print dolGetButtonAction('', $langs->trans('SetToDraft'), 'default', $_SERVER["PHP_SELF"].'?action=confirm_setdraft&amp;confirm=yes&amp;token='.newToken().'&amp;id='.$object->id, '');
1558 1558
 					} else {
1559
-						print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('SetToDraft'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1559
+						print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('SetToDraft'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1560 1560
 					}
1561 1561
 				}
1562 1562
 			}
@@ -1566,7 +1566,7 @@  discard block
 block discarded – undo
1566 1566
 				if ($userWrite > 0) {
1567 1567
 					print dolGetButtonAction('', $langs->trans('Modify'), 'default', $_SERVER["PHP_SELF"].'?action=edit&token='.newToken().'&id='.$object->id, '');
1568 1568
 				} else {
1569
-					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Modify'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1569
+					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Modify'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1570 1570
 				}
1571 1571
 			}
1572 1572
 
@@ -1575,7 +1575,7 @@  discard block
 block discarded – undo
1575 1575
 				if ($userWrite > 0) {
1576 1576
 					print dolGetButtonAction('', $langs->trans('Validate'), 'default', $_SERVER["PHP_SELF"].'?action=validate&amp;token='.newToken().'&amp;id='.$object->id, '');
1577 1577
 				} else {
1578
-					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Validate'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1578
+					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Validate'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1579 1579
 				}
1580 1580
 			}
1581 1581
 
@@ -1584,7 +1584,7 @@  discard block
 block discarded – undo
1584 1584
 				if ($userWrite > 0) {
1585 1585
 					print dolGetButtonAction('', $langs->trans('Close'), 'default', $_SERVER["PHP_SELF"].'?action=close&amp;token='.newToken().'&amp;id='.$object->id, '');
1586 1586
 				} else {
1587
-					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Close'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1587
+					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Close'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1588 1588
 				}
1589 1589
 			}
1590 1590
 
@@ -1593,7 +1593,7 @@  discard block
 block discarded – undo
1593 1593
 				if ($userWrite > 0) {
1594 1594
 					print dolGetButtonAction('', $langs->trans('ReOpen'), 'default', $_SERVER["PHP_SELF"].'?action=reopen&amp;token='.newToken().'&amp;id='.$object->id, '');
1595 1595
 				} else {
1596
-					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('ReOpen'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1596
+					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('ReOpen'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1597 1597
 				}
1598 1598
 			}
1599 1599
 
@@ -1622,7 +1622,7 @@  discard block
 block discarded – undo
1622 1622
 				if ($userWrite > 0) {
1623 1623
 					print dolGetButtonAction('', $langs->trans('ToClone'), 'default', $_SERVER["PHP_SELF"].'?action=clone&amp;token='.newToken().'&amp;id='.$object->id, '');
1624 1624
 				} else {
1625
-					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('ToClone'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1625
+					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('ToClone'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1626 1626
 				}
1627 1627
 			}
1628 1628
 
@@ -1631,7 +1631,7 @@  discard block
 block discarded – undo
1631 1631
 				if ($userDelete > 0 || ($object->statut == Project::STATUS_DRAFT && $user->hasRight('projet', 'creer'))) {
1632 1632
 					print dolGetButtonAction('', $langs->trans('Delete'), 'delete', $_SERVER["PHP_SELF"].'?action=delete&token='.newToken().'&id='.$object->id, '');
1633 1633
 				} else {
1634
-					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Delete'), 'default', $_SERVER['PHP_SELF']. '#', '', false);
1634
+					print dolGetButtonAction($langs->trans('NotOwnerOfProject'), $langs->trans('Delete'), 'default', $_SERVER['PHP_SELF'].'#', '', false);
1635 1635
 				}
1636 1636
 			}
1637 1637
 		}
Please login to merge, or discard this patch.
htdocs/public/payment/newpayment.php 1 patch
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -299,10 +299,10 @@  discard block
 block discarded – undo
299 299
 	if (getDolGlobalString('PAYMENT_SECURITY_TOKEN_UNIQUE')) {
300 300
 		if ($tmpsource && $REF) {
301 301
 			// Use the source in the hash to avoid duplicates if the references are identical
302
-			$tokenisok = dol_verifyHash(getDolGlobalString('PAYMENT_SECURITY_TOKEN') . $tmpsource.$REF, $SECUREKEY, '2');
302
+			$tokenisok = dol_verifyHash(getDolGlobalString('PAYMENT_SECURITY_TOKEN').$tmpsource.$REF, $SECUREKEY, '2');
303 303
 			// Do a second test for retro-compatibility (token may have been hashed with membersubscription in external module)
304 304
 			if ($tmpsource != $source) {
305
-				$tokenisok = dol_verifyHash(getDolGlobalString('PAYMENT_SECURITY_TOKEN') . $source.$REF, $SECUREKEY, '2');
305
+				$tokenisok = dol_verifyHash(getDolGlobalString('PAYMENT_SECURITY_TOKEN').$source.$REF, $SECUREKEY, '2');
306 306
 			}
307 307
 		} else {
308 308
 			$tokenisok = dol_verifyHash($conf->global->PAYMENT_SECURITY_TOKEN, $SECUREKEY, '2');
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
 		$tokenisok = ($conf->global->PAYMENT_SECURITY_TOKEN == $SECUREKEY);
312 312
 	}
313 313
 
314
-	if (! $tokenisok) {
314
+	if (!$tokenisok) {
315 315
 		if (!getDolGlobalString('PAYMENT_SECURITY_ACCEPT_ANY_TOKEN')) {
316 316
 			$valid = false; // PAYMENT_SECURITY_ACCEPT_ANY_TOKEN is for backward compatibility
317 317
 		} else {
@@ -340,9 +340,9 @@  discard block
 block discarded – undo
340 340
 $paramcreditor = 'ONLINE_PAYMENT_CREDITOR';
341 341
 $paramcreditorlong = 'ONLINE_PAYMENT_CREDITOR_'.$suffix;
342 342
 if (!empty($conf->global->$paramcreditorlong)) {
343
-	$creditor = $conf->global->$paramcreditorlong;	// use label long of the seller to show
343
+	$creditor = $conf->global->$paramcreditorlong; // use label long of the seller to show
344 344
 } elseif (!empty($conf->global->$paramcreditor)) {
345
-	$creditor = $conf->global->$paramcreditor;		// use label short of the seller to show
345
+	$creditor = $conf->global->$paramcreditor; // use label short of the seller to show
346 346
 }
347 347
 
348 348
 $mesg = '';
@@ -791,8 +791,8 @@  discard block
 block discarded – undo
791 791
 	$remoteip = getUserRemoteIP();
792 792
 
793 793
 	$_SESSION["onlinetoken"] = $stripeToken;
794
-	$_SESSION["FinalPaymentAmt"] = $amount;			// amount really paid (coming from Stripe). Will be used for check in paymentok.php.
795
-	$_SESSION["currencyCodeType"] = $currency;		// currency really used for payment (coming from Stripe). Will be used for check in paymentok.php.
794
+	$_SESSION["FinalPaymentAmt"] = $amount; // amount really paid (coming from Stripe). Will be used for check in paymentok.php.
795
+	$_SESSION["currencyCodeType"] = $currency; // currency really used for payment (coming from Stripe). Will be used for check in paymentok.php.
796 796
 	$_SESSION["paymentType"] = '';
797 797
 	$_SESSION['ipaddress'] = ($remoteip ? $remoteip : 'unknown'); // Payer ip
798 798
 	$_SESSION['payerID'] = is_object($customer) ? $customer->id : '';
@@ -838,7 +838,7 @@  discard block
 block discarded – undo
838 838
 
839 839
 $head = '';
840 840
 if (getDolGlobalString('ONLINE_PAYMENT_CSS_URL')) {
841
-	$head = '<link rel="stylesheet" type="text/css" href="' . getDolGlobalString('ONLINE_PAYMENT_CSS_URL').'?lang='.(!empty($getpostlang) ? $getpostlang : $langs->defaultlang).'">'."\n";
841
+	$head = '<link rel="stylesheet" type="text/css" href="'.getDolGlobalString('ONLINE_PAYMENT_CSS_URL').'?lang='.(!empty($getpostlang) ? $getpostlang : $langs->defaultlang).'">'."\n";
842 842
 }
843 843
 
844 844
 $conf->dol_hide_topmenu = 1;
@@ -962,7 +962,7 @@  discard block
 block discarded – undo
962 962
 	if (preg_match('/^\((.*)\)$/', $conf->global->PAYMENT_NEWFORM_TEXT, $reg)) {
963 963
 		$text .= $langs->trans($reg[1])."<br>\n";
964 964
 	} else {
965
-		$text .= getDolGlobalString('PAYMENT_NEWFORM_TEXT') . "<br>\n";
965
+		$text .= getDolGlobalString('PAYMENT_NEWFORM_TEXT')."<br>\n";
966 966
 	}
967 967
 	$text = '<tr><td align="center"><br>'.$text.'<br></td></tr>'."\n";
968 968
 }
@@ -1013,7 +1013,7 @@  discard block
 block discarded – undo
1013 1013
 		// Currency
1014 1014
 		print ' <b>'.$langs->trans("Currency".$currency).'</b>';
1015 1015
 	} else {
1016
-		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1016
+		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1017 1017
 		print '<input type="hidden" name="amount" value="'.$amount.'">';
1018 1018
 		print '<input type="hidden" name="newamount" value="'.$amount.'">';
1019 1019
 	}
@@ -1114,7 +1114,7 @@  discard block
 block discarded – undo
1114 1114
 		// Currency
1115 1115
 		print ' <b>'.$langs->trans("Currency".$currency).'</b>';
1116 1116
 	} else {
1117
-		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1117
+		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1118 1118
 		print '<input type="hidden" name="amount" value="'.$amount.'">';
1119 1119
 		print '<input type="hidden" name="newamount" value="'.$amount.'">';
1120 1120
 	}
@@ -1245,12 +1245,12 @@  discard block
 block discarded – undo
1245 1245
 			print '<input class="flat maxwidth75" type="text" name="newamount" value="'.price2num(GETPOST("newamount", "alpha"), 'MT').'">';
1246 1246
 			print ' <b>'.$langs->trans("Currency".$currency).'</b>';
1247 1247
 		} else {
1248
-			print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1248
+			print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1249 1249
 			print '<input type="hidden" name="amount" value="'.$amount.'">';
1250 1250
 			print '<input type="hidden" name="newamount" value="'.$amount.'">';
1251 1251
 		}
1252 1252
 	} else {
1253
-		print '<b class="amount">'.price($object->total_ttc, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1253
+		print '<b class="amount">'.price($object->total_ttc, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1254 1254
 	}
1255 1255
 	print '<input type="hidden" name="currency" value="'.$currency.'">';
1256 1256
 	print '</td></tr>'."\n";
@@ -1445,7 +1445,7 @@  discard block
 block discarded – undo
1445 1445
 		// Currency
1446 1446
 		print ' <b>'.$langs->trans("Currency".$currency).'</b>';
1447 1447
 	} else {
1448
-		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1448
+		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1449 1449
 		print '<input type="hidden" name="amount" value="'.$amount.'">';
1450 1450
 		print '<input type="hidden" name="newamount" value="'.$amount.'">';
1451 1451
 	}
@@ -1496,7 +1496,7 @@  discard block
 block discarded – undo
1496 1496
 if ($source == 'member' || $source == 'membersubscription') {
1497 1497
 	$newsource = 'member';
1498 1498
 
1499
-	$tag="";
1499
+	$tag = "";
1500 1500
 	$found = true;
1501 1501
 	$langs->load("members");
1502 1502
 
@@ -1647,7 +1647,7 @@  discard block
 block discarded – undo
1647 1647
 	print '<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans("Amount");
1648 1648
 	// This place no longer allows amount edition
1649 1649
 	if (getDolGlobalString('MEMBER_EXT_URL_SUBSCRIPTION_INFO')) {
1650
-		print ' - <a href="' . getDolGlobalString('MEMBER_EXT_URL_SUBSCRIPTION_INFO').'" rel="external" target="_blank" rel="noopener noreferrer">'.$langs->trans("SeeHere").'</a>';
1650
+		print ' - <a href="'.getDolGlobalString('MEMBER_EXT_URL_SUBSCRIPTION_INFO').'" rel="external" target="_blank" rel="noopener noreferrer">'.$langs->trans("SeeHere").'</a>';
1651 1651
 	}
1652 1652
 	print '</td><td class="CTableRow2">';
1653 1653
 	if (getDolGlobalString('MEMBER_MIN_AMOUNT') && $amount) {
@@ -1663,9 +1663,9 @@  discard block
 block discarded – undo
1663 1663
 			print '<input type="text" class="width75" name="newamount" value="'.price($amount, 1, $langs, 1, -1, -1).'">';
1664 1664
 		}
1665 1665
 	} else {
1666
-		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1666
+		print '<b class="amount">'.price($amount, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1667 1667
 		if ($minimumamount > $amount) {
1668
-			print ' &nbsp; <span class="opacitymedium small">'. $langs->trans("AmountIsLowerToMinimumNotice", price($minimumamount, 1, $langs, 1, -1, -1, $currency)).'</span>';
1668
+			print ' &nbsp; <span class="opacitymedium small">'.$langs->trans("AmountIsLowerToMinimumNotice", price($minimumamount, 1, $langs, 1, -1, -1, $currency)).'</span>';
1669 1669
 		}
1670 1670
 		print '<input type="hidden" name="newamount" value="'.$amount.'">';
1671 1671
 	}
@@ -1785,7 +1785,7 @@  discard block
 block discarded – undo
1785 1785
 			print ' ('.$langs->trans("ToComplete");
1786 1786
 		}
1787 1787
 		if (getDolGlobalString('DONATION_EXT_URL_SUBSCRIPTION_INFO')) {
1788
-			print ' - <a href="' . getDolGlobalString('DONATION_EXT_URL_SUBSCRIPTION_INFO').'" rel="external" target="_blank" rel="noopener noreferrer">'.$langs->trans("SeeHere").'</a>';
1788
+			print ' - <a href="'.getDolGlobalString('DONATION_EXT_URL_SUBSCRIPTION_INFO').'" rel="external" target="_blank" rel="noopener noreferrer">'.$langs->trans("SeeHere").'</a>';
1789 1789
 		}
1790 1790
 		if (!getDolGlobalString('DONATION_NEWFORM_AMOUNT')) {
1791 1791
 			print ')';
@@ -1823,7 +1823,7 @@  discard block
 block discarded – undo
1823 1823
 			$valtoshow = max(getDolGlobalString('DONATION_MIN_AMOUNT'), $valtoshow);
1824 1824
 			$amount = $valtoshow;
1825 1825
 		}
1826
-		print '<b class="amount">'.price($valtoshow, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1826
+		print '<b class="amount">'.price($valtoshow, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1827 1827
 		print '<input type="hidden" name="amount" value="'.$valtoshow.'">';
1828 1828
 		print '<input type="hidden" name="newamount" value="'.$valtoshow.'">';
1829 1829
 	}
@@ -1899,7 +1899,7 @@  discard block
 block discarded – undo
1899 1899
 	print '</b>';
1900 1900
 	print '</td></tr>'."\n";
1901 1901
 
1902
-	if (! is_object($attendee->project)) {
1902
+	if (!is_object($attendee->project)) {
1903 1903
 		$text = 'ErrorProjectNotFound';
1904 1904
 	} else {
1905 1905
 		$text = $langs->trans("PaymentEvent").' - '.$attendee->project->title;
@@ -1916,7 +1916,7 @@  discard block
 block discarded – undo
1916 1916
 	print '<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans("Amount");
1917 1917
 	print '</td><td class="CTableRow2">';
1918 1918
 	$valtoshow = $amount;
1919
-	print '<b class="amount">'.price($valtoshow, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
1919
+	print '<b class="amount">'.price($valtoshow, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
1920 1920
 	print '<input type="hidden" name="amount" value="'.$valtoshow.'">';
1921 1921
 	print '<input type="hidden" name="newamount" value="'.$valtoshow.'">';
1922 1922
 	print '<input type="hidden" name="currency" value="'.$currency.'">';
@@ -2000,7 +2000,7 @@  discard block
 block discarded – undo
2000 2000
 	print '<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans("Amount");
2001 2001
 	print '</td><td class="CTableRow2">';
2002 2002
 	$valtoshow = $amount;
2003
-	print '<b class="amount">'.price($valtoshow, 1, $langs, 1, -1, -1, $currency).'</b>';	// Price with currency
2003
+	print '<b class="amount">'.price($valtoshow, 1, $langs, 1, -1, -1, $currency).'</b>'; // Price with currency
2004 2004
 	print '<input type="hidden" name="amount" value="'.$valtoshow.'">';
2005 2005
 	print '<input type="hidden" name="newamount" value="'.$valtoshow.'">';
2006 2006
 	print '<input type="hidden" name="currency" value="'.$currency.'">';
@@ -2237,7 +2237,7 @@  discard block
 block discarded – undo
2237 2237
 
2238 2238
 		//print '<br>';
2239 2239
 
2240
-		print '<!-- Show Stripe form payment-form STRIPE_USE_INTENT_WITH_AUTOMATIC_CONFIRMATION = ' . getDolGlobalString('STRIPE_USE_INTENT_WITH_AUTOMATIC_CONFIRMATION').' STRIPE_USE_NEW_CHECKOUT = ' . getDolGlobalString('STRIPE_USE_NEW_CHECKOUT').' -->'."\n";
2240
+		print '<!-- Show Stripe form payment-form STRIPE_USE_INTENT_WITH_AUTOMATIC_CONFIRMATION = '.getDolGlobalString('STRIPE_USE_INTENT_WITH_AUTOMATIC_CONFIRMATION').' STRIPE_USE_NEW_CHECKOUT = '.getDolGlobalString('STRIPE_USE_NEW_CHECKOUT').' -->'."\n";
2241 2241
 		print '<form action="'.$_SERVER['REQUEST_URI'].'" method="POST" id="payment-form">'."\n";
2242 2242
 
2243 2243
 		print '<input type="hidden" name="token" value="'.newToken().'">'."\n";
Please login to merge, or discard this patch.
htdocs/societe/ajax/company.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
 	$match = preg_grep('/('.preg_quote($htmlname, '/').'[0-9]+)/', array_keys($_GET));
104 104
 	sort($match);
105 105
 
106
-	$id = (!empty($match[0]) ? $match[0] : '');		// Take first key found into GET array with matching $htmlname123
106
+	$id = (!empty($match[0]) ? $match[0] : ''); // Take first key found into GET array with matching $htmlname123
107 107
 
108 108
 	// When used from jQuery, the search term is added as GET param "term".
109 109
 	$searchkey = (($id && GETPOST($id, 'alpha')) ? GETPOST($id, 'alpha') : (($htmlname && GETPOST($htmlname, 'alpha')) ? GETPOST($htmlname, 'alpha') : ''));
Please login to merge, or discard this patch.
htdocs/societe/card.php 1 patch
Spacing   +52 added lines, -52 removed lines patch added patch discarded remove patch
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
 $backtopage = GETPOST('backtopage', 'alpha');
103 103
 $backtopageforcancel = GETPOST('backtopageforcancel', 'alpha');
104 104
 $backtopagejsfields = GETPOST('backtopagejsfields', 'alpha');
105
-$confirm 	= GETPOST('confirm', 'alpha');
105
+$confirm = GETPOST('confirm', 'alpha');
106 106
 
107 107
 $dol_openinpopup = '';
108 108
 if (!empty($backtopagejsfields)) {
@@ -151,12 +151,12 @@  discard block
 block discarded – undo
151 151
 }
152 152
 
153 153
 // Permissions
154
-$permissiontoread 	= $user->hasRight('societe', 'lire');
155
-$permissiontoadd 	= $user->hasRight('societe', 'creer'); // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php
154
+$permissiontoread = $user->hasRight('societe', 'lire');
155
+$permissiontoadd = $user->hasRight('societe', 'creer'); // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php
156 156
 $permissiontodelete = $user->hasRight('societe', 'supprimer') || ($permissiontoadd && isset($object->status) && $object->status == 0);
157
-$permissionnote 	= $user->hasRight('societe', 'creer'); // Used by the include of actions_setnotes.inc.php
157
+$permissionnote = $user->hasRight('societe', 'creer'); // Used by the include of actions_setnotes.inc.php
158 158
 $permissiondellink 	= $user->hasRight('societe', 'creer'); // Used by the include of actions_dellink.inc.php
159
-$upload_dir 		= $conf->societe->multidir_output[isset($object->entity) ? $object->entity : 1];
159
+$upload_dir = $conf->societe->multidir_output[isset($object->entity) ? $object->entity : 1];
160 160
 
161 161
 // Security check
162 162
 $result = restrictedArea($user, 'societe', $socid, '&societe', '', 'fk_soc', 'rowid', 0);
@@ -199,7 +199,7 @@  discard block
 block discarded – undo
199 199
 
200 200
 	if ($action == 'confirm_merge' && $confirm == 'yes' && $user->hasRight('societe', 'creer')) {
201 201
 		$soc_origin_id = GETPOST('soc_origin', 'int');
202
-		$soc_origin = new Societe($db);		// The thirdparty that we will delete
202
+		$soc_origin = new Societe($db); // The thirdparty that we will delete
203 203
 
204 204
 		if ($soc_origin_id <= 0) {
205 205
 			$langs->load('errors');
@@ -288,12 +288,12 @@  discard block
 block discarded – undo
288 288
 			$error++;
289 289
 		}
290 290
 
291
-		if (isModEnabled('mailing') && getDolGlobalInt('MAILING_CONTACT_DEFAULT_BULK_STATUS') == 2 && GETPOST('contact_no_email', 'int')==-1 && !empty(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL))) {
291
+		if (isModEnabled('mailing') && getDolGlobalInt('MAILING_CONTACT_DEFAULT_BULK_STATUS') == 2 && GETPOST('contact_no_email', 'int') == -1 && !empty(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL))) {
292 292
 			$error++;
293 293
 			setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("No_Email")), null, 'errors');
294 294
 		}
295 295
 
296
-		if (isModEnabled('mailing') && GETPOST("private", 'int') == 1 && getDolGlobalInt('MAILING_CONTACT_DEFAULT_BULK_STATUS') == 2 && GETPOST('contact_no_email', 'int')==-1 && !empty(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL))) {
296
+		if (isModEnabled('mailing') && GETPOST("private", 'int') == 1 && getDolGlobalInt('MAILING_CONTACT_DEFAULT_BULK_STATUS') == 2 && GETPOST('contact_no_email', 'int') == -1 && !empty(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL))) {
297 297
 			$error++;
298 298
 			setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("No_Email")), null, 'errors');
299 299
 		}
@@ -312,19 +312,19 @@  discard block
 block discarded – undo
312 312
 				$object->name = dolGetFirstLastname(GETPOST('firstname', 'alphanohtml'), GETPOST('name', 'alphanohtml'));
313 313
 				$object->civility_id		= GETPOST('civility_id', 'alphanohtml'); // Note: civility id is a code, not an int
314 314
 				// Add non official properties
315
-				$object->name_bis			= GETPOST('name', 'alphanohtml');
316
-				$object->firstname			= GETPOST('firstname', 'alphanohtml');
315
+				$object->name_bis = GETPOST('name', 'alphanohtml');
316
+				$object->firstname = GETPOST('firstname', 'alphanohtml');
317 317
 			} else {
318
-				$object->name				= GETPOST('name', 'alphanohtml');
318
+				$object->name = GETPOST('name', 'alphanohtml');
319 319
 			}
320 320
 			$object->entity					= (GETPOSTISSET('entity') ? GETPOST('entity', 'int') : $conf->entity);
321
-			$object->name_alias				= GETPOST('name_alias', 'alphanohtml');
321
+			$object->name_alias = GETPOST('name_alias', 'alphanohtml');
322 322
 			$object->parent					= GETPOST('parent_company_id', 'int');
323 323
 			$object->address				= GETPOST('address', 'alphanohtml');
324
-			$object->zip					= GETPOST('zipcode', 'alphanohtml');
325
-			$object->town					= GETPOST('town', 'alphanohtml');
326
-			$object->country_id				= GETPOST('country_id', 'int');
327
-			$object->state_id				= GETPOST('state_id', 'int');
324
+			$object->zip = GETPOST('zipcode', 'alphanohtml');
325
+			$object->town = GETPOST('town', 'alphanohtml');
326
+			$object->country_id = GETPOST('country_id', 'int');
327
+			$object->state_id = GETPOST('state_id', 'int');
328 328
 
329 329
 			$object->socialnetworks = array();
330 330
 			if (isModEnabled('socialnetworks')) {
@@ -338,7 +338,7 @@  discard block
 block discarded – undo
338 338
 			$object->phone					= GETPOST('phone', 'alpha');
339 339
 			$object->fax					= GETPOST('fax', 'alpha');
340 340
 			$object->email					= trim(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL));
341
-			$object->no_email 				= GETPOST("no_email", "int");
341
+			$object->no_email = GETPOST("no_email", "int");
342 342
 			$object->url					= trim(GETPOST('url', 'custom', 0, FILTER_SANITIZE_URL));
343 343
 			$object->idprof1				= trim(GETPOST('idprof1', 'alphanohtml'));
344 344
 			$object->idprof2				= trim(GETPOST('idprof2', 'alphanohtml'));
@@ -348,13 +348,13 @@  discard block
 block discarded – undo
348 348
 			$object->idprof6				= trim(GETPOST('idprof6', 'alphanohtml'));
349 349
 			$object->prefix_comm			= GETPOST('prefix_comm', 'alphanohtml');
350 350
 			$object->code_client			= GETPOSTISSET('customer_code') ? GETPOST('customer_code', 'alpha') : GETPOST('code_client', 'alpha');
351
-			$object->code_fournisseur		= GETPOSTISSET('supplier_code') ? GETPOST('supplier_code', 'alpha') : GETPOST('code_fournisseur', 'alpha');
351
+			$object->code_fournisseur = GETPOSTISSET('supplier_code') ? GETPOST('supplier_code', 'alpha') : GETPOST('code_fournisseur', 'alpha');
352 352
 			$object->capital				= GETPOST('capital', 'alphanohtml');
353 353
 			$object->barcode				= GETPOST('barcode', 'alphanohtml');
354 354
 
355 355
 			$object->tva_intra				= GETPOST('tva_intra', 'alphanohtml');
356 356
 			$object->tva_assuj				= GETPOST('assujtva_value', 'alpha');
357
-			$object->vat_reverse_charge		= GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
357
+			$object->vat_reverse_charge = GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
358 358
 			$object->status = GETPOST('status', 'alpha');
359 359
 
360 360
 			// Local Taxes
@@ -364,24 +364,24 @@  discard block
 block discarded – undo
364 364
 			$object->localtax1_value		= GETPOST('lt1', 'alpha');
365 365
 			$object->localtax2_value		= GETPOST('lt2', 'alpha');
366 366
 
367
-			$object->forme_juridique_code	= GETPOST('forme_juridique_code', 'int');
367
+			$object->forme_juridique_code = GETPOST('forme_juridique_code', 'int');
368 368
 			$object->effectif_id			= GETPOST('effectif_id', 'int');
369
-			$object->typent_id				= GETPOST('typent_id', 'int');
369
+			$object->typent_id = GETPOST('typent_id', 'int');
370 370
 
371 371
 			$object->typent_code			= dol_getIdFromCode($db, $object->typent_id, 'c_typent', 'id', 'code'); // Force typent_code too so check in verify() will be done on new type
372 372
 
373
-			$object->client					= GETPOST('client', 'int');
373
+			$object->client = GETPOST('client', 'int');
374 374
 			$object->fournisseur			= GETPOST('fournisseur', 'int');
375 375
 
376
-			$object->commercial_id			= GETPOST('commercial_id', 'int');
377
-			$object->default_lang			= GETPOST('default_lang');
376
+			$object->commercial_id = GETPOST('commercial_id', 'int');
377
+			$object->default_lang = GETPOST('default_lang');
378 378
 
379 379
 			// Webservices url/key
380 380
 			$object->webservices_url		= GETPOST('webservices_url', 'custom', 0, FILTER_SANITIZE_URL);
381 381
 			$object->webservices_key		= GETPOST('webservices_key', 'san_alpha');
382 382
 
383 383
 			if (GETPOSTISSET('accountancy_code_sell')) {
384
-				$accountancy_code_sell		= GETPOST('accountancy_code_sell', 'alpha');
384
+				$accountancy_code_sell = GETPOST('accountancy_code_sell', 'alpha');
385 385
 
386 386
 				if (empty($accountancy_code_sell) || $accountancy_code_sell == '-1') {
387 387
 					$object->accountancy_code_sell = '';
@@ -390,7 +390,7 @@  discard block
 block discarded – undo
390 390
 				}
391 391
 			}
392 392
 			if (GETPOSTISSET('accountancy_code_buy')) {
393
-				$accountancy_code_buy		= GETPOST('accountancy_code_buy', 'alpha');
393
+				$accountancy_code_buy = GETPOST('accountancy_code_buy', 'alpha');
394 394
 
395 395
 				if (empty($accountancy_code_buy) || $accountancy_code_buy == '-1') {
396 396
 					$object->accountancy_code_buy = '';
@@ -1004,7 +1004,7 @@  discard block
 block discarded – undo
1004 1004
 		$object->civility_id		= GETPOST('civility_id', 'alpha');
1005 1005
 
1006 1006
 		$object->tva_assuj = GETPOST('assujtva_value', 'int');
1007
-		$object->vat_reverse_charge	= GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
1007
+		$object->vat_reverse_charge = GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
1008 1008
 		$object->status = GETPOST('status', 'int');
1009 1009
 
1010 1010
 		//Local Taxes
@@ -1020,7 +1020,7 @@  discard block
 block discarded – undo
1020 1020
 		$object->default_lang = GETPOST('default_lang');
1021 1021
 
1022 1022
 		if (GETPOSTISSET('accountancy_code_sell')) {
1023
-			$accountancy_code_sell  = GETPOST('accountancy_code_sell', 'alpha');
1023
+			$accountancy_code_sell = GETPOST('accountancy_code_sell', 'alpha');
1024 1024
 
1025 1025
 			if (empty($accountancy_code_sell) || $accountancy_code_sell == '-1') {
1026 1026
 				$object->accountancy_code_sell = '';
@@ -1029,7 +1029,7 @@  discard block
 block discarded – undo
1029 1029
 			}
1030 1030
 		}
1031 1031
 		if (GETPOSTISSET('accountancy_code_buy')) {
1032
-			$accountancy_code_buy   = GETPOST('accountancy_code_buy', 'alpha');
1032
+			$accountancy_code_buy = GETPOST('accountancy_code_buy', 'alpha');
1033 1033
 
1034 1034
 			if (empty($accountancy_code_buy) || $accountancy_code_buy == '-1') {
1035 1035
 				$object->accountancy_code_buy = '';
@@ -1154,7 +1154,7 @@  discard block
 block discarded – undo
1154 1154
 
1155 1155
 			print '<script type="text/javascript">';
1156 1156
 			print '$(document).ready(function () {
1157
-					var canHaveCategoryIfNotCustomerProspectSupplier = ' . (!getDolGlobalString('THIRDPARTY_CAN_HAVE_CATEGORY_EVEN_IF_NOT_CUSTOMER_PROSPECT') ? '0' : '1') . ';
1157
+					var canHaveCategoryIfNotCustomerProspectSupplier = ' . (!getDolGlobalString('THIRDPARTY_CAN_HAVE_CATEGORY_EVEN_IF_NOT_CUSTOMER_PROSPECT') ? '0' : '1').';
1158 1158
 
1159 1159
 					init_customer_categ();
1160 1160
 			  		$("#customerprospect").change(function() {
@@ -1226,7 +1226,7 @@  discard block
 block discarded – undo
1226 1226
 			print '</td><td'.(!getDolGlobalString('SOCIETE_USEPREFIX') ? ' colspan="3"' : '').'>';
1227 1227
 
1228 1228
 			print '<input type="text" class="minwidth300" maxlength="128" name="name" id="name" value="'.dol_escape_htmltag($object->name).'" autofocus="autofocus">';
1229
-			print $form->widgetForTranslation("name", $object, $permissiontoadd, 'string', 'alpahnohtml', 'minwidth300');	// For some countries that need the company name in 2 languages
1229
+			print $form->widgetForTranslation("name", $object, $permissiontoadd, 'string', 'alpahnohtml', 'minwidth300'); // For some countries that need the company name in 2 languages
1230 1230
 			// This implementation of the feature to search already existing company has been disabled. It must be implemented by keeping the "input text" and we must call the search ajax societe/ajax/ajaxcompanies.php
1231 1231
 			// on a keydown of the input. We should show data about a duplicate found if we found less than 5 answers into a div under the input.
1232 1232
 			/*
@@ -1484,7 +1484,7 @@  discard block
 block discarded – undo
1484 1484
 				if ($conf->browser->layout == 'phone') {
1485 1485
 					print '</tr><tr>';
1486 1486
 				}
1487
-				print '<td class="individualline noemail">'.$form->editfieldkey($langs->trans('No_Email') .' ('.$langs->trans('Contact').')', 'contact_no_email', '', $object, 0).'</td>';
1487
+				print '<td class="individualline noemail">'.$form->editfieldkey($langs->trans('No_Email').' ('.$langs->trans('Contact').')', 'contact_no_email', '', $object, 0).'</td>';
1488 1488
 				print '<td class="individualline" '.(($conf->browser->layout == 'phone') || !isModEnabled('mailing') ? ' colspan="3"' : '').'>'.$form->selectyesno('contact_no_email', (GETPOSTISSET("contact_no_email") ? GETPOST("contact_no_email", 'alpha') : (empty($object->no_email) ? 0 : 1)), 1, false, 1).'</td>';
1489 1489
 			}
1490 1490
 			print '</tr>';
@@ -1557,7 +1557,7 @@  discard block
 block discarded – undo
1557 1557
 			// Vat is used
1558 1558
 			print '<tr><td>'.$form->editfieldkey('VATIsUsed', 'assujtva_value', '', $object, 0).'</td>';
1559 1559
 			print '<td>';
1560
-			print '<input id="assujtva_value" name="assujtva_value" type="checkbox" ' . (GETPOSTISSET('assujtva_value') ? 'checked="checked"' : 'checked="checked"') . ' value="1">'; // Assujeti par defaut en creation
1560
+			print '<input id="assujtva_value" name="assujtva_value" type="checkbox" '.(GETPOSTISSET('assujtva_value') ? 'checked="checked"' : 'checked="checked"').' value="1">'; // Assujeti par defaut en creation
1561 1561
 			print '</td>';
1562 1562
 			if ($conf->browser->layout == 'phone') {
1563 1563
 				print '</tr><tr>';
@@ -1598,7 +1598,7 @@  discard block
 block discarded – undo
1598 1598
 
1599 1599
 			// VAT reverse charge by default
1600 1600
 			if (getDolGlobalString('ACCOUNTING_FORCE_ENABLE_VAT_REVERSE_CHARGE')) {
1601
-				print '<tr><td>' . $form->editfieldkey('VATReverseChargeByDefault', 'vat_reverse_charge', '', $object, 0) . '</td><td colspan="3">';
1601
+				print '<tr><td>'.$form->editfieldkey('VATReverseChargeByDefault', 'vat_reverse_charge', '', $object, 0).'</td><td colspan="3">';
1602 1602
 				print '<input type="checkbox" name="vat_reverse_charge" '.($object->vat_reverse_charge == '1' ? ' checked' : '').'>';
1603 1603
 				print '</td></tr>';
1604 1604
 			}
@@ -1607,21 +1607,21 @@  discard block
 block discarded – undo
1607 1607
 			//TODO: Place into a function to control showing by country or study better option
1608 1608
 			if ($mysoc->localtax1_assuj == "1" && $mysoc->localtax2_assuj == "1") {
1609 1609
 				print '<tr><td>'.$langs->transcountry("LocalTax1IsUsed", $mysoc->country_code).'</td><td>';
1610
-				print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" ' . (isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX1) ? 'checked="checked"' : '') . ' value="1">';
1610
+				print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" '.(isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX1) ? 'checked="checked"' : '').' value="1">';
1611 1611
 				print '</td>';
1612 1612
 				if ($conf->browser->layout == 'phone') {
1613 1613
 					print '</tr><tr>';
1614 1614
 				}
1615 1615
 				print '<td>'.$langs->transcountry("LocalTax2IsUsed", $mysoc->country_code).'</td><td>';
1616
-				print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" ' . (isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX2) ? 'checked="checked"' : '') . ' value="1">';
1616
+				print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" '.(isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX2) ? 'checked="checked"' : '').' value="1">';
1617 1617
 				print '</td></tr>';
1618 1618
 			} elseif ($mysoc->localtax1_assuj == "1") {
1619 1619
 				print '<tr><td>'.$langs->transcountry("LocalTax1IsUsed", $mysoc->country_code).'</td><td colspan="3">';
1620
-				print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" ' . (isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX1) ? 'checked="checked"' : '') . ' value="1">';
1620
+				print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" '.(isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX1) ? 'checked="checked"' : '').' value="1">';
1621 1621
 				print '</td></tr>';
1622 1622
 			} elseif ($mysoc->localtax2_assuj == "1") {
1623 1623
 				print '<tr><td>'.$langs->transcountry("LocalTax2IsUsed", $mysoc->country_code).'</td><td colspan="3">';
1624
-				print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" ' . (isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX2) ? 'checked="checked"' : '') . ' value="1">';
1624
+				print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" '.(isset($conf->global->THIRDPARTY_DEFAULT_USELOCALTAX2) ? 'checked="checked"' : '').' value="1">';
1625 1625
 				print '</td></tr>';
1626 1626
 			}
1627 1627
 
@@ -1863,7 +1863,7 @@  discard block
 block discarded – undo
1863 1863
 				$object->phone					= GETPOST('phone', 'alpha');
1864 1864
 				$object->fax					= GETPOST('fax', 'alpha');
1865 1865
 				$object->email					= GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL);
1866
-				$object->no_email				= GETPOST("no_email", "int");
1866
+				$object->no_email = GETPOST("no_email", "int");
1867 1867
 				$object->url					= GETPOST('url', 'custom', 0, FILTER_SANITIZE_URL);
1868 1868
 				$object->capital				= GETPOST('capital', 'alphanohtml');
1869 1869
 				$object->idprof1				= GETPOST('idprof1', 'alphanohtml');
@@ -1879,16 +1879,16 @@  discard block
 block discarded – undo
1879 1879
 				$object->default_lang = GETPOST('default_lang', 'alpha');
1880 1880
 
1881 1881
 				$object->tva_assuj				= GETPOST('assujtva_value', 'int');
1882
-				$object->vat_reverse_charge		= GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
1882
+				$object->vat_reverse_charge = GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
1883 1883
 				$object->tva_intra				= GETPOST('tva_intra', 'alphanohtml');
1884
-				$object->status =				GETPOST('status', 'int');
1884
+				$object->status = GETPOST('status', 'int');
1885 1885
 
1886 1886
 				// Webservices url/key
1887 1887
 				$object->webservices_url        = GETPOST('webservices_url', 'custom', 0, FILTER_SANITIZE_URL);
1888 1888
 				$object->webservices_key        = GETPOST('webservices_key', 'san_alpha');
1889 1889
 
1890 1890
 				if (GETPOSTISSET('accountancy_code_sell')) {
1891
-					$accountancy_code_sell  = GETPOST('accountancy_code_sell', 'alpha');
1891
+					$accountancy_code_sell = GETPOST('accountancy_code_sell', 'alpha');
1892 1892
 
1893 1893
 					if (empty($accountancy_code_sell) || $accountancy_code_sell == '-1') {
1894 1894
 						$object->accountancy_code_sell = '';
@@ -1897,7 +1897,7 @@  discard block
 block discarded – undo
1897 1897
 					}
1898 1898
 				}
1899 1899
 				if (GETPOSTISSET('accountancy_code_buy')) {
1900
-					$accountancy_code_buy   = GETPOST('accountancy_code_buy', 'alpha');
1900
+					$accountancy_code_buy = GETPOST('accountancy_code_buy', 'alpha');
1901 1901
 
1902 1902
 					if (empty($accountancy_code_buy) || $accountancy_code_buy == '-1') {
1903 1903
 						$object->accountancy_code_buy = '';
@@ -1979,7 +1979,7 @@  discard block
 block discarded – undo
1979 1979
     				}
1980 1980
     			});
1981 1981
 
1982
-				var canHaveCategoryIfNotCustomerProspectSupplier = ' . (!getDolGlobalString('THIRDPARTY_CAN_HAVE_CUSTOMER_CATEGORY_EVEN_IF_NOT_CUSTOMER_PROSPECT') ? '0' : '1') . ';
1982
+				var canHaveCategoryIfNotCustomerProspectSupplier = ' . (!getDolGlobalString('THIRDPARTY_CAN_HAVE_CUSTOMER_CATEGORY_EVEN_IF_NOT_CUSTOMER_PROSPECT') ? '0' : '1').';
1983 1983
 
1984 1984
 				init_customer_categ();
1985 1985
 	  			$("#customerprospect").change(function() {
@@ -2293,14 +2293,14 @@  discard block
 block discarded – undo
2293 2293
 
2294 2294
 				// VAT is used
2295 2295
 				print '<tr><td>'.$form->editfieldkey('VATIsUsed', 'assujtva_value', '', $object, 0).'</td><td colspan="3">';
2296
-				print '<input id="assujtva_value" name="assujtva_value" type="checkbox" ' . ($object->tva_assuj ? 'checked="checked"' : '') . ' value="1">';
2296
+				print '<input id="assujtva_value" name="assujtva_value" type="checkbox" '.($object->tva_assuj ? 'checked="checked"' : '').' value="1">';
2297 2297
 				print '</td></tr>';
2298 2298
 
2299 2299
 				// Local Taxes
2300 2300
 				//TODO: Place into a function to control showing by country or study better option
2301 2301
 				if ($mysoc->localtax1_assuj == "1" && $mysoc->localtax2_assuj == "1") {
2302 2302
 					print '<tr><td>'.$form->editfieldkey($langs->transcountry("LocalTax1IsUsed", $mysoc->country_code), 'localtax1assuj_value', '', $object, 0).'</td><td>';
2303
-					print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" ' . ($object->localtax1_assuj ? 'checked="checked"' : '') . ' value="1">';
2303
+					print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" '.($object->localtax1_assuj ? 'checked="checked"' : '').' value="1">';
2304 2304
 					if (!isOnlyOneLocalTax(1)) {
2305 2305
 						print '<span class="cblt1">     '.$langs->transcountry("Type", $mysoc->country_code).': ';
2306 2306
 						$formcompany->select_localtax(1, $object->localtax1_value, "lt1");
@@ -2309,7 +2309,7 @@  discard block
 block discarded – undo
2309 2309
 					print '</td>';
2310 2310
 					print '</tr><tr>';
2311 2311
 					print '<td>'.$form->editfieldkey($langs->transcountry("LocalTax2IsUsed", $mysoc->country_code), 'localtax2assuj_value', '', $object, 0).'</td><td>';
2312
-					print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" ' . ($object->localtax2_assuj ? 'checked="checked"' : '') . ' value="1"></td></tr>';
2312
+					print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" '.($object->localtax2_assuj ? 'checked="checked"' : '').' value="1"></td></tr>';
2313 2313
 					if (!isOnlyOneLocalTax(2)) {
2314 2314
 						print '<span class="cblt2">     '.$langs->transcountry("Type", $mysoc->country_code).': ';
2315 2315
 						$formcompany->select_localtax(2, $object->localtax2_value, "lt2");
@@ -2318,7 +2318,7 @@  discard block
 block discarded – undo
2318 2318
 					print '</td></tr>';
2319 2319
 				} elseif ($mysoc->localtax1_assuj == "1" && $mysoc->localtax2_assuj != "1") {
2320 2320
 					print '<tr><td>'.$form->editfieldkey($langs->transcountry("LocalTax1IsUsed", $mysoc->country_code), 'localtax1assuj_value', '', $object, 0).'</td><td colspan="3">';
2321
-					print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" ' . ($object->localtax1_assuj ? 'checked="checked"' : '') . ' value="1">';
2321
+					print '<input id="localtax1assuj_value" name="localtax1assuj_value" type="checkbox" '.($object->localtax1_assuj ? 'checked="checked"' : '').' value="1">';
2322 2322
 					if (!isOnlyOneLocalTax(1)) {
2323 2323
 						print '<span class="cblt1">     '.$langs->transcountry("Type", $mysoc->country_code).': ';
2324 2324
 						$formcompany->select_localtax(1, $object->localtax1_value, "lt1");
@@ -2327,7 +2327,7 @@  discard block
 block discarded – undo
2327 2327
 					print '</td></tr>';
2328 2328
 				} elseif ($mysoc->localtax2_assuj == "1" && $mysoc->localtax1_assuj != "1") {
2329 2329
 					print '<tr><td>'.$form->editfieldkey($langs->transcountry("LocalTax2IsUsed", $mysoc->country_code), 'localtax2assuj_value', '', $object, 0).'</td><td colspan="3">';
2330
-					print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" ' . ($object->localtax2_assuj ? 'checked="checked"' : '') . ' value="1">';
2330
+					print '<input id="localtax2assuj_value" name="localtax2assuj_value" type="checkbox" '.($object->localtax2_assuj ? 'checked="checked"' : '').' value="1">';
2331 2331
 					if (!isOnlyOneLocalTax(2)) {
2332 2332
 						print '<span class="cblt2">     '.$langs->transcountry("Type", $mysoc->country_code).': ';
2333 2333
 						$formcompany->select_localtax(2, $object->localtax2_value, "lt2");
@@ -2338,7 +2338,7 @@  discard block
 block discarded – undo
2338 2338
 
2339 2339
 				// VAT reverse charge by default
2340 2340
 				if (getDolGlobalString('ACCOUNTING_FORCE_ENABLE_VAT_REVERSE_CHARGE')) {
2341
-					print '<tr><td>' . $form->editfieldkey('VATReverseChargeByDefault', 'vat_reverse_charge', '', $object, 0) . '</td><td colspan="3">';
2341
+					print '<tr><td>'.$form->editfieldkey('VATReverseChargeByDefault', 'vat_reverse_charge', '', $object, 0).'</td><td colspan="3">';
2342 2342
 					print '<input type="checkbox" name="vat_reverse_charge" '.($object->vat_reverse_charge == '1' ? ' checked' : '').'>';
2343 2343
 					print '</td></tr>';
2344 2344
 				}
@@ -2515,7 +2515,7 @@  discard block
 block discarded – undo
2515 2515
 					$maxfilesizearray = getMaxFileSizeArray();
2516 2516
 					$maxmin = $maxfilesizearray['maxmin'];
2517 2517
 					if ($maxmin > 0) {
2518
-						print '<input type="hidden" name="MAX_FILE_SIZE" value="'.($maxmin * 1024).'">';	// MAX_FILE_SIZE must precede the field type=file
2518
+						print '<input type="hidden" name="MAX_FILE_SIZE" value="'.($maxmin * 1024).'">'; // MAX_FILE_SIZE must precede the field type=file
2519 2519
 					}
2520 2520
 					print '<input type="file" class="flat" name="photo" id="photoinput">';
2521 2521
 					print '</td></tr>';
@@ -2736,7 +2736,7 @@  discard block
 block discarded – undo
2736 2736
 					print '<tr><td>';
2737 2737
 					print $form->textwithpicto($langs->trans('VATReverseChargeByDefault'), $langs->trans('VATReverseChargeByDefaultDesc'));
2738 2738
 					print '</td><td>';
2739
-					print '<input type="checkbox" name="vat_reverse_charge" ' . ($object->vat_reverse_charge == '1' ? ' checked' : '') . ' disabled>';
2739
+					print '<input type="checkbox" name="vat_reverse_charge" '.($object->vat_reverse_charge == '1' ? ' checked' : '').' disabled>';
2740 2740
 					print '</td>';
2741 2741
 					print '</tr>';
2742 2742
 				}
Please login to merge, or discard this patch.
htdocs/societe/paymentmodes.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
 			// Ajout
292 292
 			$companybankaccount = new CompanyBankAccount($db);
293 293
 
294
-			$companybankaccount->socid           = $object->id;
294
+			$companybankaccount->socid = $object->id;
295 295
 
296 296
 			$companybankaccount->fetch_thirdparty();
297 297
 
@@ -586,7 +586,7 @@  discard block
 block discarded – undo
586 586
 		}
587 587
 		if ($action == 'syncsepatostripe') {
588 588
 			// Create the bank account on current Stripe env
589
-			$companypaymentmode = new CompanyPaymentMode($db);	// Get record in llx_societe_rib
589
+			$companypaymentmode = new CompanyPaymentMode($db); // Get record in llx_societe_rib
590 590
 			$companypaymentmode->fetch($id);
591 591
 
592 592
 			if ($companypaymentmode->type != 'ban') {
@@ -1180,7 +1180,7 @@  discard block
 block discarded – undo
1180 1180
 		print '<table class="liste centpercent">'."\n";
1181 1181
 		print '<tr class="liste_titre">';
1182 1182
 		print '<td>'.$langs->trans('Label').'</td>';
1183
-		print '<td>'.$form->textwithpicto($langs->trans('ExternalSystemID'), $langs->trans("IDOfPaymentInAnExternalSystem")).'</td>';	// external system ID
1183
+		print '<td>'.$form->textwithpicto($langs->trans('ExternalSystemID'), $langs->trans("IDOfPaymentInAnExternalSystem")).'</td>'; // external system ID
1184 1184
 		print '<td>'.$langs->trans('Type').'</td>';
1185 1185
 		print '<td>'.$langs->trans('Informations').'</td>';
1186 1186
 		print '<td></td>';
@@ -1520,7 +1520,7 @@  discard block
 block discarded – undo
1520 1520
 
1521 1521
 	// List of bank accounts
1522 1522
 	if ($permissiontoaddupdatepaymentinformation) {
1523
-		$morehtmlright = dolGetButtonTitle($langs->trans('Add'), '', 'fa fa-plus-circle', $_SERVER["PHP_SELF"] . '?socid=' . $object->id . '&amp;action=create');
1523
+		$morehtmlright = dolGetButtonTitle($langs->trans('Add'), '', 'fa fa-plus-circle', $_SERVER["PHP_SELF"].'?socid='.$object->id.'&amp;action=create');
1524 1524
 	}
1525 1525
 
1526 1526
 	print load_fiche_titre($langs->trans("BankAccounts"), $morehtmlright, 'bank');
@@ -1537,7 +1537,7 @@  discard block
 block discarded – undo
1537 1537
 
1538 1538
 		print '<tr class="liste_titre">';
1539 1539
 		print_liste_field_titre("Label");
1540
-		print_liste_field_titre($form->textwithpicto($langs->trans('ExternalSystemID'), $langs->trans("IDOfPaymentInAnExternalSystem")));		// external system ID
1540
+		print_liste_field_titre($form->textwithpicto($langs->trans('ExternalSystemID'), $langs->trans("IDOfPaymentInAnExternalSystem"))); // external system ID
1541 1541
 		print_liste_field_titre("Bank");
1542 1542
 		print_liste_field_titre("RIB");
1543 1543
 		print_liste_field_titre("IBAN");
@@ -1733,7 +1733,7 @@  discard block
 block discarded – undo
1733 1733
 				print '<td class="right nowraponall">';
1734 1734
 				$useonlinesignature = 1;
1735 1735
 				if ($useonlinesignature) {
1736
-					require_once DOL_DOCUMENT_ROOT . '/core/lib/signature.lib.php';
1736
+					require_once DOL_DOCUMENT_ROOT.'/core/lib/signature.lib.php';
1737 1737
 					print showOnlineSignatureUrl($companybankaccount->element, $rib->id);
1738 1738
 				}
1739 1739
 				print '</td>';
Please login to merge, or discard this patch.
htdocs/societe/contact.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
 $action		= (GETPOST('action', 'aZ09') ? GETPOST('action', 'aZ09') : 'view');
68 68
 $cancel 	= GETPOST('cancel', 'alpha');
69 69
 $backtopage = GETPOST('backtopage', 'alpha');
70
-$confirm 	= GETPOST('confirm');
70
+$confirm = GETPOST('confirm');
71 71
 $socid 		= GETPOST('socid', 'int') ? GETPOST('socid', 'int') : GETPOST('id', 'int');
72 72
 
73 73
 if ($user->socid) {
Please login to merge, or discard this patch.
htdocs/societe/checkvat/checkVatPopup.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
  *		\brief      Popup screen to validate VAT
22 22
  */
23 23
 
24
-if (! defined('NOTOKENRENEWAL')) {
24
+if (!defined('NOTOKENRENEWAL')) {
25 25
 	define('NOTOKENRENEWAL', '1');
26 26
 }		// Do not roll the Anti CSRF token (used if MAIN_SECURITY_CSRF_WITH_TOKEN is on)
27 27
 
Please login to merge, or discard this patch.
htdocs/societe/consumption.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -52,10 +52,10 @@
 block discarded – undo
52 52
 }
53 53
 
54 54
 // Sort & Order fields
55
-$limit 		= GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit;
55
+$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit;
56 56
 $sortfield 	= GETPOST('sortfield', 'aZ09comma');
57 57
 $sortorder 	= GETPOST('sortorder', 'aZ09comma');
58
-$page 		= GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int');
58
+$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int');
59 59
 $optioncss 	= GETPOST('optioncss', 'alpha');
60 60
 
61 61
 if (empty($page) || $page == -1) {
Please login to merge, or discard this patch.
htdocs/societe/website.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -45,11 +45,11 @@  discard block
 block discarded – undo
45 45
 // Get parameters
46 46
 $id = GETPOST('id', 'int') ? GETPOST('id', 'int') : GETPOST('socid', 'int');
47 47
 
48
-$action 	 = GETPOST('action', 'aZ09') ? GETPOST('action', 'aZ09') : 'view';               // The action 'add', 'create', 'edit', 'update', 'view', ...
48
+$action = GETPOST('action', 'aZ09') ? GETPOST('action', 'aZ09') : 'view'; // The action 'add', 'create', 'edit', 'update', 'view', ...
49 49
 $show_files  = GETPOST('show_files', 'int');
50
-$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'websitelist';  // To manage different context of search
51
-$backtopage  = GETPOST('backtopage', 'alpha');                                              // Go back to a dedicated page
52
-$optioncss   = GETPOST('optioncss', 'aZ');                                                  // Option for the css output (always '' except when 'print')
50
+$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'websitelist'; // To manage different context of search
51
+$backtopage  = GETPOST('backtopage', 'alpha'); // Go back to a dedicated page
52
+$optioncss   = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print')
53 53
 $toselect   = GETPOST('toselect', 'array'); // Array of ids of elements selected into a list
54 54
 $optioncss  = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print')
55 55
 $mode       = GETPOST('mode', 'aZ'); // The output mode ('list', 'kanban', 'hierarchy', 'calendar', ...)
@@ -489,7 +489,7 @@  discard block
 block discarded – undo
489 489
 	} elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && !in_array($key, array('id', 'rowid', 'ref', 'status')) && $val['label'] != 'TechnicalID' && empty($val['arrayofkeyval'])) {
490 490
 		$cssforfield .= ($cssforfield ? ' ' : '').'right';
491 491
 	}
492
-	$cssforfield = preg_replace('/small\s*/', '', $cssforfield);	// the 'small' css must not be used for the title label
492
+	$cssforfield = preg_replace('/small\s*/', '', $cssforfield); // the 'small' css must not be used for the title label
493 493
 	if (!empty($arrayfields['t.'.$key]['checked'])) {
494 494
 		print getTitleFieldOfList($arrayfields['t.'.$key]['label'], 0, $_SERVER['PHP_SELF'], 't.'.$key, '', $param, ($cssforfield ? 'class="'.$cssforfield.'"' : ''), $sortfield, $sortorder, ($cssforfield ? $cssforfield.' ' : ''), 0, (empty($val['helplist']) ? '' : $val['helplist']))."\n";
495 495
 		$totalarray['nbfield']++;
Please login to merge, or discard this patch.