@@ -334,7 +334,7 @@ |
||
| 334 | 334 | if ((!isModEnabled('multicurrency') || $object->multicurrency_tx == 1) && $row->code == "LIQ" && $row->pos_change > 0) { |
| 335 | 335 | echo '<tr>'; |
| 336 | 336 | echo '<td class="right">'; |
| 337 | - echo $langs->trans("Change"); // ChangeBack ? |
|
| 337 | + echo $langs->trans("Change"); // ChangeBack ? |
|
| 338 | 338 | echo '</td>'; |
| 339 | 339 | echo '<td class="right">'; |
| 340 | 340 | echo price($row->pos_change, 1, '', 1, -1, -1, $currency); |
@@ -26,11 +26,11 @@ discard block |
||
| 26 | 26 | defineIfNotDefined('NOREQUIREMENU', '1'); |
| 27 | 27 | |
| 28 | 28 | if (!defined('NOLOGIN')) { |
| 29 | - define('NOLOGIN', '1'); // If this page is public (can be called outside logged session) |
|
| 29 | + define('NOLOGIN', '1'); // If this page is public (can be called outside logged session) |
|
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | if (!defined('NOIPCHECK')) { |
| 33 | - define('NOIPCHECK', '1'); // Do not check IP defined into conf $dolibarr_main_restrict_ip |
|
| 33 | + define('NOIPCHECK', '1'); // Do not check IP defined into conf $dolibarr_main_restrict_ip |
|
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | defineIfNotDefined('NOBROWSERNOTIF', '1'); |
@@ -90,8 +90,8 @@ discard block |
||
| 90 | 90 | print '<a href="list.php' . (!empty($entity) && isModEnabled('multicompany') ? '?entity=' . $entity : '') . '" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_display bigrounded"><span class="fa fa-15 fa-list-alt valignmiddle btnTitle-icon"></span><br>' . dol_escape_htmltag($langs->trans("ViewMyTicketList")) . '</div></a>'; |
| 91 | 91 | print '<a href="view.php' . (!empty($entity) && isModEnabled('multicompany') ? '?entity=' . $entity : '') . '" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_display bigrounded">' . img_picto('', 'ticket', 'class="fa-15"') . '<br>' . dol_escape_htmltag($langs->trans("ShowTicketWithTrackId")) . '</div></a>'; |
| 92 | 92 | print '<div class="clearboth"></div>'; |
| 93 | -print '</div>'; // ends '<div class="ticketform">'; |
|
| 94 | -print '</div>'; // ends '<div class="ticketpublicarea ticketlargemargin centpercent">'; |
|
| 93 | +print '</div>'; // ends '<div class="ticketform">'; |
|
| 94 | +print '</div>'; // ends '<div class="ticketpublicarea ticketlargemargin centpercent">'; |
|
| 95 | 95 | |
| 96 | 96 | if (getDolGlobalInt('TICKET_SHOW_COMPANY_FOOTER')) { |
| 97 | 97 | // End of page |
@@ -33,11 +33,11 @@ discard block |
||
| 33 | 33 | defineIfNotDefined('NOREQUIREMENU', '1'); // If there is no need to load and show top and left menu |
| 34 | 34 | defineIfNotDefined('NOIPCHECK', '1'); // Do not check IP defined into conf $dolibarr_main_restrict_ip |
| 35 | 35 | defineIfNotDefined('NOSESSION', '1'); |
| 36 | -if (! defined('NOREQUIREHTML')) { |
|
| 37 | - define('NOREQUIREHTML', '1'); // If we don't need to load the html.form.class.php |
|
| 36 | +if (!defined('NOREQUIREHTML')) { |
|
| 37 | + define('NOREQUIREHTML', '1'); // If we don't need to load the html.form.class.php |
|
| 38 | 38 | } |
| 39 | -if (! defined('NOREQUIREAJAX')) { |
|
| 40 | - define('NOREQUIREAJAX', '1'); // Do not load ajax.lib.php library |
|
| 39 | +if (!defined('NOREQUIREAJAX')) { |
|
| 40 | + define('NOREQUIREAJAX', '1'); // Do not load ajax.lib.php library |
|
| 41 | 41 | } |
| 42 | 42 | |
| 43 | 43 | |
@@ -51,7 +51,7 @@ discard block |
||
| 51 | 51 | |
| 52 | 52 | $mtid = GETPOST('mtid'); |
| 53 | 53 | $email = GETPOST('email'); |
| 54 | -$tag = GETPOST('tag'); // To retrieve the emailing, and recipient |
|
| 54 | +$tag = GETPOST('tag'); // To retrieve the emailing, and recipient |
|
| 55 | 55 | $unsuscrib = GETPOST('unsuscrib'); |
| 56 | 56 | $securitykey = GETPOST('securitykey'); |
| 57 | 57 | |
@@ -136,7 +136,7 @@ discard block |
||
| 136 | 136 | //print "before decoding $val\n"; |
| 137 | 137 | do { |
| 138 | 138 | $oldval = $val; |
| 139 | - $val = html_entity_decode($val, ENT_QUOTES | ENT_HTML5); // Decode ':', ''', '	', '&NewLine', ... |
|
| 139 | + $val = html_entity_decode($val, ENT_QUOTES | ENT_HTML5); // Decode ':', ''', '	', '&NewLine', ... |
|
| 140 | 140 | // Sometimes we have entities without the ; at end so html_entity_decode does not work but entities is still interpreted by browser. |
| 141 | 141 | $val = preg_replace_callback( |
| 142 | 142 | '/&#(x?[0-9][0-9a-f]+;?)/i', |
@@ -145,7 +145,7 @@ discard block |
||
| 145 | 145 | * |
| 146 | 146 | * @return string |
| 147 | 147 | */ |
| 148 | - static function ($m) { |
|
| 148 | + static function($m) { |
|
| 149 | 149 | // Decode 'n', ... |
| 150 | 150 | return realCharForNumericEntities($m); |
| 151 | 151 | }, |
@@ -186,7 +186,7 @@ discard block |
||
| 186 | 186 | $inj += preg_match('/user\s*\(/i', $val); // avoid to use function user() or mysql_user() that return current database login |
| 187 | 187 | $inj += preg_match('/information_schema/i', $val); // avoid to use request that read information_schema database |
| 188 | 188 | $inj += preg_match('/<svg/i', $val); // <svg can be allowed in POST |
| 189 | - $inj += preg_match('/update[^&=\w].*set.+=/i', $val); // the [^&=\w] test is to avoid error when request is like action=update&...set... or &updatemodule=...set... |
|
| 189 | + $inj += preg_match('/update[^&=\w].*set.+=/i', $val); // the [^&=\w] test is to avoid error when request is like action=update&...set... or &updatemodule=...set... |
|
| 190 | 190 | $inj += preg_match('/union.+select/i', $val); |
| 191 | 191 | } |
| 192 | 192 | if ($type == 3) { |
@@ -436,7 +436,7 @@ discard block |
||
| 436 | 436 | session_set_cookie_params($sessioncookieparams); |
| 437 | 437 | } |
| 438 | 438 | session_name($sessionname); |
| 439 | - session_start(); // This call the open and read of session handler |
|
| 439 | + session_start(); // This call the open and read of session handler |
|
| 440 | 440 | //exit; // this exist generates a call to write and close |
| 441 | 441 | } |
| 442 | 442 | |
@@ -713,7 +713,7 @@ discard block |
||
| 713 | 713 | unset($_GET['action']); |
| 714 | 714 | unset($_GET['confirmmassaction']); |
| 715 | 715 | unset($_GET['massaction']); |
| 716 | - unset($_GET['token']); // TODO Make a redirect if we have a token in url to remove it ? |
|
| 716 | + unset($_GET['token']); // TODO Make a redirect if we have a token in url to remove it ? |
|
| 717 | 717 | if (isset($savid)) { |
| 718 | 718 | $_POST['id'] = ((int) $savid); |
| 719 | 719 | } |
@@ -159,7 +159,7 @@ discard block |
||
| 159 | 159 | * @param string $arg |
| 160 | 160 | * @return bool |
| 161 | 161 | */ |
| 162 | - static function ($arg) { |
|
| 162 | + static function($arg) { |
|
| 163 | 163 | return strlen($arg) >= 2 && $arg[0] == '-'; |
| 164 | 164 | } |
| 165 | 165 | ); |
@@ -169,7 +169,7 @@ discard block |
||
| 169 | 169 | * @param string $arg |
| 170 | 170 | * @return string |
| 171 | 171 | */ |
| 172 | - static function ($arg) { |
|
| 172 | + static function($arg) { |
|
| 173 | 173 | if (strlen($arg) > 1) { |
| 174 | 174 | return "--" . $arg; |
| 175 | 175 | } |
@@ -307,10 +307,10 @@ discard block |
||
| 307 | 307 | |
| 308 | 308 | // Check install.lock (for both install and upgrade) |
| 309 | 309 | |
| 310 | -$lockfile = DOL_DATA_ROOT . '/install.lock'; // To lock all /install pages |
|
| 310 | +$lockfile = DOL_DATA_ROOT . '/install.lock'; // To lock all /install pages |
|
| 311 | 311 | $lockfile2 = DOL_DOCUMENT_ROOT . '/install.lock'; // To lock all /install pages (recommended) |
| 312 | -$upgradeunlockfile = DOL_DATA_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 313 | -$upgradeunlockfile2 = DOL_DOCUMENT_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 312 | +$upgradeunlockfile = DOL_DATA_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 313 | +$upgradeunlockfile2 = DOL_DOCUMENT_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 314 | 314 | if (constant('DOL_DATA_ROOT') === null) { |
| 315 | 315 | // We don't have a configuration file yet |
| 316 | 316 | // Try to detect any lockfile in the default documents path |
@@ -319,7 +319,7 @@ discard block |
||
| 319 | 319 | } |
| 320 | 320 | $islocked = false; |
| 321 | 321 | if (@file_exists($lockfile) || @file_exists($lockfile2)) { |
| 322 | - if (!defined('ALLOWED_IF_UPGRADE_UNLOCK_FOUND') || (! @file_exists($upgradeunlockfile) && ! @file_exists($upgradeunlockfile2))) { |
|
| 322 | + if (!defined('ALLOWED_IF_UPGRADE_UNLOCK_FOUND') || (!@file_exists($upgradeunlockfile) && !@file_exists($upgradeunlockfile2))) { |
|
| 323 | 323 | // If this is a dangerous install page (ALLOWED_IF_UPGRADE_UNLOCK_FOUND not defined) or |
| 324 | 324 | // if there is no upgrade unlock files, we lock the pages. |
| 325 | 325 | $islocked = true; |
@@ -494,7 +494,7 @@ discard block |
||
| 494 | 494 | if (defined('SYSLOG_FILE')) { |
| 495 | 495 | $conf->global->SYSLOG_FILE = constant('SYSLOG_FILE'); |
| 496 | 496 | } |
| 497 | - defineIfNotDefined('SYSLOG_FILE_NO_ERROR', '1'); // We init log handler for install |
|
| 497 | + defineIfNotDefined('SYSLOG_FILE_NO_ERROR', '1'); // We init log handler for install |
|
| 498 | 498 | $handlers = array('mod_syslog_file'); |
| 499 | 499 | foreach ($handlers as $handler) { |
| 500 | 500 | $file = DOL_DOCUMENT_ROOT . '/core/modules/syslog/' . $handler . '.php'; |
@@ -42,7 +42,7 @@ |
||
| 42 | 42 | //if (! defined("MAIN_AUTHENTICATION_MODE")) define('MAIN_AUTHENTICATION_MODE', 'aloginmodule'); // Force authentication handler |
| 43 | 43 | //if (! defined('CSRFCHECK_WITH_TOKEN')) define('CSRFCHECK_WITH_TOKEN', '1'); // Force use of CSRF protection with tokens even for GET |
| 44 | 44 | //if (! defined('NOBROWSERNOTIF')) define('NOBROWSERNOTIF', '1'); // Disable browser notification |
| 45 | -defineIfNotDefined('NOSESSION', '1'); // On CLI mode, no need to use web sessions |
|
| 45 | +defineIfNotDefined('NOSESSION', '1'); // On CLI mode, no need to use web sessions |
|
| 46 | 46 | |
| 47 | 47 | |
| 48 | 48 | $sapi_type = php_sapi_name(); |
@@ -291,7 +291,7 @@ discard block |
||
| 291 | 291 | if (!empty($_SERVER["HTTP_USER_AGENT"]) && $_SERVER["HTTP_USER_AGENT"] == 'securitytest') { |
| 292 | 292 | http_response_code(401); // It makes easier to understand if session was broken during security tests |
| 293 | 293 | } |
| 294 | - dol_loginfunction($langs, $conf, (!empty($mysoc) ? $mysoc : '')); // This include http headers |
|
| 294 | + dol_loginfunction($langs, $conf, (!empty($mysoc) ? $mysoc : '')); // This include http headers |
|
| 295 | 295 | } |
| 296 | 296 | exit; |
| 297 | 297 | } |
@@ -639,6 +639,6 @@ discard block |
||
| 639 | 639 | } else { |
| 640 | 640 | // We may have NOLOGIN set, but NOREQUIREUSER not |
| 641 | 641 | if (!empty($user) && method_exists($user, 'loadDefaultValues') && !defined('NODEFAULTVALUES')) { |
| 642 | - $user->loadDefaultValues(); // Load default values for everybody (works even if $user->id = 0 |
|
| 642 | + $user->loadDefaultValues(); // Load default values for everybody (works even if $user->id = 0 |
|
| 643 | 643 | } |
| 644 | 644 | } |
@@ -156,7 +156,7 @@ discard block |
||
| 156 | 156 | * @param string $arg |
| 157 | 157 | * @return bool |
| 158 | 158 | */ |
| 159 | - static function ($arg) { |
|
| 159 | + static function($arg) { |
|
| 160 | 160 | return strlen($arg) >= 2 && $arg[0] == '-'; |
| 161 | 161 | } |
| 162 | 162 | ); |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | * @param string $arg |
| 167 | 167 | * @return string |
| 168 | 168 | */ |
| 169 | - static function ($arg) { |
|
| 169 | + static function($arg) { |
|
| 170 | 170 | if (strlen($arg) > 1) { |
| 171 | 171 | return "--" . $arg; |
| 172 | 172 | } |
@@ -304,10 +304,10 @@ discard block |
||
| 304 | 304 | |
| 305 | 305 | // Check install.lock (for both install and upgrade) |
| 306 | 306 | |
| 307 | -$lockfile = DOL_DATA_ROOT . '/install.lock'; // To lock all /install pages |
|
| 307 | +$lockfile = DOL_DATA_ROOT . '/install.lock'; // To lock all /install pages |
|
| 308 | 308 | $lockfile2 = DOL_DOCUMENT_ROOT . '/install.lock'; // To lock all /install pages (recommended) |
| 309 | -$upgradeunlockfile = DOL_DATA_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 310 | -$upgradeunlockfile2 = DOL_DOCUMENT_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 309 | +$upgradeunlockfile = DOL_DATA_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 310 | +$upgradeunlockfile2 = DOL_DOCUMENT_ROOT . '/upgrade.unlock'; // To unlock upgrade process |
|
| 311 | 311 | if (constant('DOL_DATA_ROOT') === null) { |
| 312 | 312 | // We don't have a configuration file yet |
| 313 | 313 | // Try to detect any lockfile in the default documents path |
@@ -316,7 +316,7 @@ discard block |
||
| 316 | 316 | } |
| 317 | 317 | $islocked = false; |
| 318 | 318 | if (@file_exists($lockfile) || @file_exists($lockfile2)) { |
| 319 | - if (!defined('ALLOWED_IF_UPGRADE_UNLOCK_FOUND') || (! @file_exists($upgradeunlockfile) && ! @file_exists($upgradeunlockfile2))) { |
|
| 319 | + if (!defined('ALLOWED_IF_UPGRADE_UNLOCK_FOUND') || (!@file_exists($upgradeunlockfile) && !@file_exists($upgradeunlockfile2))) { |
|
| 320 | 320 | // If this is a dangerous install page (ALLOWED_IF_UPGRADE_UNLOCK_FOUND not defined) or |
| 321 | 321 | // if there is no upgrade unlock files, we lock the pages. |
| 322 | 322 | $islocked = true; |
@@ -486,7 +486,7 @@ discard block |
||
| 486 | 486 | if (defined('SYSLOG_FILE')) { |
| 487 | 487 | $conf->global->SYSLOG_FILE = constant('SYSLOG_FILE'); |
| 488 | 488 | } |
| 489 | - defineIfNotDefined('SYSLOG_FILE_NO_ERROR', '1'); // We init log handler for install |
|
| 489 | + defineIfNotDefined('SYSLOG_FILE_NO_ERROR', '1'); // We init log handler for install |
|
| 490 | 490 | $handlers = array('mod_syslog_file'); |
| 491 | 491 | foreach ($handlers as $handler) { |
| 492 | 492 | $file = DOL_DOCUMENT_ROOT . '/core/modules/syslog/' . $handler . '.php'; |