@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | $this->db = $db; |
| 60 | 60 | } |
| 61 | 61 | |
| 62 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 62 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 63 | 63 | /** |
| 64 | 64 | * Function called when a Dolibarr business event occurs |
| 65 | 65 | * This function call all qualified triggers. |
@@ -73,7 +73,7 @@ discard block |
||
| 73 | 73 | */ |
| 74 | 74 | public function run_triggers($action, $object, $user, $langs, $conf) |
| 75 | 75 | { |
| 76 | - // phpcs:enable |
|
| 76 | + // phpcs:enable |
|
| 77 | 77 | |
| 78 | 78 | if (getDolGlobalInt('MAIN_TRIGGER_DEBUG')) { |
| 79 | 79 | // This his too much verbose, enabled if const enabled only |
@@ -847,7 +847,7 @@ discard block |
||
| 847 | 847 | return $this->LibStatut($this->status, $mode); |
| 848 | 848 | } |
| 849 | 849 | |
| 850 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 850 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 851 | 851 | /** |
| 852 | 852 | * Return the status |
| 853 | 853 | * |
@@ -857,7 +857,7 @@ discard block |
||
| 857 | 857 | */ |
| 858 | 858 | public function LibStatut($status, $mode = 0) |
| 859 | 859 | { |
| 860 | - // phpcs:enable |
|
| 860 | + // phpcs:enable |
|
| 861 | 861 | if (empty($this->labelStatus) || empty($this->labelStatusShort)) { |
| 862 | 862 | global $langs; |
| 863 | 863 | //$langs->load("timespent@timespent"); |
@@ -117,7 +117,7 @@ discard block |
||
| 117 | 117 | } |
| 118 | 118 | } |
| 119 | 119 | |
| 120 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 120 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 121 | 121 | /** |
| 122 | 122 | * Output edit area inside the HTML stream. |
| 123 | 123 | * Output depends on this->tool (fckeditor, ckeditor, textarea, ...) |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | */ |
| 134 | 134 | public function Create($noprint = 0, $morejs = '', $disallowAnyContent = true, $titlecontent = '', $option = '', $moreparam = '', $morecss = '') |
| 135 | 135 | { |
| 136 | - // phpcs:enable |
|
| 136 | + // phpcs:enable |
|
| 137 | 137 | global $conf, $langs; |
| 138 | 138 | |
| 139 | 139 | $fullpage = false; |
@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | define('REQUIRE_CKEDITOR', '1'); |
| 159 | 159 | } |
| 160 | 160 | |
| 161 | - $skin = getDolGlobalString('FCKEDITOR_SKIN', 'moono-lisa'); // default with ckeditor 4.6 : moono-lisa |
|
| 161 | + $skin = getDolGlobalString('FCKEDITOR_SKIN', 'moono-lisa'); // default with ckeditor 4.6 : moono-lisa |
|
| 162 | 162 | |
| 163 | 163 | $pluginstodisable = 'elementspath,save,flash,div,anchor'; |
| 164 | 164 | if (!getDolGlobalString('FCKEDITOR_ENABLE_SPECIALCHAR')) { |
@@ -259,7 +259,7 @@ discard block |
||
| 259 | 259 | filebrowserImageWindowWidth : \'900\', |
| 260 | 260 | filebrowserImageWindowHeight : \'500\''; |
| 261 | 261 | } |
| 262 | - $out .= ' })' . $morejs; // end CKEditor.replace |
|
| 262 | + $out .= ' })' . $morejs; // end CKEditor.replace |
|
| 263 | 263 | // Show the CKEditor javascript object once loaded is ready 'For debug) |
| 264 | 264 | //$out .= '; CKEDITOR.on(\'instanceReady\', function(ck) { ck.editor.removeMenuItem(\'maximize\'); ck.editor.removeMenuItem(\'Undo\'); ck.editor.removeMenuItem(\'undo\'); console.log(ck.editor); console.log(ck.editor.toolbar[0]); }); '; |
| 265 | 265 | $out .= '});' . "\n"; // end document.ready |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | } |
| 46 | 46 | } |
| 47 | 47 | |
| 48 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 48 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 49 | 49 | /** |
| 50 | 50 | * SetOpenIDServer |
| 51 | 51 | * |
@@ -54,11 +54,11 @@ discard block |
||
| 54 | 54 | */ |
| 55 | 55 | public function SetOpenIDServer($a) |
| 56 | 56 | { |
| 57 | - // phpcs:enable |
|
| 57 | + // phpcs:enable |
|
| 58 | 58 | $this->URLs['openid_server'] = $a; |
| 59 | 59 | } |
| 60 | 60 | |
| 61 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 61 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 62 | 62 | /** |
| 63 | 63 | * SetOpenIDServer |
| 64 | 64 | * |
@@ -67,11 +67,11 @@ discard block |
||
| 67 | 67 | */ |
| 68 | 68 | public function SetTrustRoot($a) |
| 69 | 69 | { |
| 70 | - // phpcs:enable |
|
| 70 | + // phpcs:enable |
|
| 71 | 71 | $this->URLs['trust_root'] = $a; |
| 72 | 72 | } |
| 73 | 73 | |
| 74 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 74 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 75 | 75 | /** |
| 76 | 76 | * SetOpenIDServer |
| 77 | 77 | * |
@@ -80,11 +80,11 @@ discard block |
||
| 80 | 80 | */ |
| 81 | 81 | public function SetCancelURL($a) |
| 82 | 82 | { |
| 83 | - // phpcs:enable |
|
| 83 | + // phpcs:enable |
|
| 84 | 84 | $this->URLs['cancel'] = $a; |
| 85 | 85 | } |
| 86 | 86 | |
| 87 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 87 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 88 | 88 | /** |
| 89 | 89 | * SetApprovedURL |
| 90 | 90 | * |
@@ -93,11 +93,11 @@ discard block |
||
| 93 | 93 | */ |
| 94 | 94 | public function SetApprovedURL($a) |
| 95 | 95 | { |
| 96 | - // phpcs:enable |
|
| 96 | + // phpcs:enable |
|
| 97 | 97 | $this->URLs['approved'] = $a; |
| 98 | 98 | } |
| 99 | 99 | |
| 100 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 100 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 101 | 101 | /** |
| 102 | 102 | * SetRequiredFields |
| 103 | 103 | * |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | */ |
| 107 | 107 | public function SetRequiredFields($a) |
| 108 | 108 | { |
| 109 | - // phpcs:enable |
|
| 109 | + // phpcs:enable |
|
| 110 | 110 | if (is_array($a)) { |
| 111 | 111 | $this->fields['required'] = $a; |
| 112 | 112 | } else { |
@@ -114,7 +114,7 @@ discard block |
||
| 114 | 114 | } |
| 115 | 115 | } |
| 116 | 116 | |
| 117 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 117 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 118 | 118 | /** |
| 119 | 119 | * SetOptionalFields |
| 120 | 120 | * |
@@ -123,7 +123,7 @@ discard block |
||
| 123 | 123 | */ |
| 124 | 124 | public function SetOptionalFields($a) |
| 125 | 125 | { |
| 126 | - // phpcs:enable |
|
| 126 | + // phpcs:enable |
|
| 127 | 127 | if (is_array($a)) { |
| 128 | 128 | $this->fields['optional'] = $a; |
| 129 | 129 | } else { |
@@ -131,7 +131,7 @@ discard block |
||
| 131 | 131 | } |
| 132 | 132 | } |
| 133 | 133 | |
| 134 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 134 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 135 | 135 | /** |
| 136 | 136 | * SetIdentity |
| 137 | 137 | * |
@@ -140,7 +140,7 @@ discard block |
||
| 140 | 140 | */ |
| 141 | 141 | public function SetIdentity($a) |
| 142 | 142 | { |
| 143 | - // phpcs:enable |
|
| 143 | + // phpcs:enable |
|
| 144 | 144 | // Set Identity URL |
| 145 | 145 | if ( |
| 146 | 146 | (stripos($a, 'http://') === false) |
@@ -164,7 +164,7 @@ discard block |
||
| 164 | 164 | $this->openid_url_identity = $a; |
| 165 | 165 | } |
| 166 | 166 | |
| 167 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 167 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 168 | 168 | /** |
| 169 | 169 | * GetIdentity |
| 170 | 170 | * |
@@ -172,12 +172,12 @@ discard block |
||
| 172 | 172 | */ |
| 173 | 173 | public function GetIdentity() |
| 174 | 174 | { |
| 175 | - // phpcs:enable |
|
| 175 | + // phpcs:enable |
|
| 176 | 176 | // Get Identity |
| 177 | 177 | return $this->openid_url_identity; |
| 178 | 178 | } |
| 179 | 179 | |
| 180 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 180 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 181 | 181 | /** |
| 182 | 182 | * SetOpenIDServer |
| 183 | 183 | * |
@@ -185,12 +185,12 @@ discard block |
||
| 185 | 185 | */ |
| 186 | 186 | public function GetError() |
| 187 | 187 | { |
| 188 | - // phpcs:enable |
|
| 188 | + // phpcs:enable |
|
| 189 | 189 | $e = $this->error; |
| 190 | 190 | return array('code' => $e[0], 'description' => $e[1]); |
| 191 | 191 | } |
| 192 | 192 | |
| 193 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 193 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 194 | 194 | /** |
| 195 | 195 | * ErrorStore |
| 196 | 196 | * |
@@ -200,7 +200,7 @@ discard block |
||
| 200 | 200 | */ |
| 201 | 201 | public function ErrorStore($code, $desc = null) |
| 202 | 202 | { |
| 203 | - // phpcs:enable |
|
| 203 | + // phpcs:enable |
|
| 204 | 204 | $errs = array(); |
| 205 | 205 | $errs['OPENID_NOSERVERSFOUND'] = 'Cannot find OpenID Server TAG on Identity page.'; |
| 206 | 206 | if ($desc == null) { |
@@ -209,7 +209,7 @@ discard block |
||
| 209 | 209 | $this->error = array($code, $desc); |
| 210 | 210 | } |
| 211 | 211 | |
| 212 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 212 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 213 | 213 | /** |
| 214 | 214 | * IsError |
| 215 | 215 | * |
@@ -217,7 +217,7 @@ discard block |
||
| 217 | 217 | */ |
| 218 | 218 | public function IsError() |
| 219 | 219 | { |
| 220 | - // phpcs:enable |
|
| 220 | + // phpcs:enable |
|
| 221 | 221 | if (count($this->error) > 0) { |
| 222 | 222 | return true; |
| 223 | 223 | } else { |
@@ -245,7 +245,7 @@ discard block |
||
| 245 | 245 | return $r; |
| 246 | 246 | } |
| 247 | 247 | |
| 248 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 248 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 249 | 249 | /** |
| 250 | 250 | * OpenID_Standarize |
| 251 | 251 | * |
@@ -254,7 +254,7 @@ discard block |
||
| 254 | 254 | */ |
| 255 | 255 | public function OpenID_Standarize($openid_identity = null) |
| 256 | 256 | { |
| 257 | - // phpcs:enable |
|
| 257 | + // phpcs:enable |
|
| 258 | 258 | if ($openid_identity === null) { |
| 259 | 259 | $openid_identity = $this->openid_url_identity; |
| 260 | 260 | } |
@@ -293,7 +293,7 @@ discard block |
||
| 293 | 293 | return $query; |
| 294 | 294 | } |
| 295 | 295 | |
| 296 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 296 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 297 | 297 | /** |
| 298 | 298 | * FSOCK_Request |
| 299 | 299 | * |
@@ -304,7 +304,7 @@ discard block |
||
| 304 | 304 | */ |
| 305 | 305 | public function FSOCK_Request($url, $method = "GET", $params = "") |
| 306 | 306 | { |
| 307 | - // phpcs:enable |
|
| 307 | + // phpcs:enable |
|
| 308 | 308 | $fp = fsockopen("ssl://www.myopenid.com", 443, $errno, $errstr, 3); // Connection timeout is 3 seconds |
| 309 | 309 | if (!$fp) { |
| 310 | 310 | $this->ErrorStore('OPENID_SOCKETERROR', $errstr); |
@@ -327,7 +327,7 @@ discard block |
||
| 327 | 327 | } |
| 328 | 328 | } |
| 329 | 329 | |
| 330 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 330 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 331 | 331 | /** |
| 332 | 332 | * HTML2OpenIDServer |
| 333 | 333 | * |
@@ -336,7 +336,7 @@ discard block |
||
| 336 | 336 | */ |
| 337 | 337 | public function HTML2OpenIDServer($content) |
| 338 | 338 | { |
| 339 | - // phpcs:enable |
|
| 339 | + // phpcs:enable |
|
| 340 | 340 | $get = array(); |
| 341 | 341 | |
| 342 | 342 | $matches1 = array(); |
@@ -358,7 +358,7 @@ discard block |
||
| 358 | 358 | } |
| 359 | 359 | |
| 360 | 360 | |
| 361 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 361 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 362 | 362 | /** |
| 363 | 363 | * Get openid server |
| 364 | 364 | * |
@@ -367,7 +367,7 @@ discard block |
||
| 367 | 367 | */ |
| 368 | 368 | public function GetOpenIDServer($url = '') |
| 369 | 369 | { |
| 370 | - // phpcs:enable |
|
| 370 | + // phpcs:enable |
|
| 371 | 371 | global $conf; |
| 372 | 372 | |
| 373 | 373 | include_once DOL_DOCUMENT_ROOT . '/core/lib/geturl.lib.php'; |
@@ -392,7 +392,7 @@ discard block |
||
| 392 | 392 | return $servers[0]; |
| 393 | 393 | } |
| 394 | 394 | |
| 395 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 395 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 396 | 396 | /** |
| 397 | 397 | * GetRedirectURL |
| 398 | 398 | * |
@@ -400,7 +400,7 @@ discard block |
||
| 400 | 400 | */ |
| 401 | 401 | public function GetRedirectURL() |
| 402 | 402 | { |
| 403 | - // phpcs:enable |
|
| 403 | + // phpcs:enable |
|
| 404 | 404 | $params = array(); |
| 405 | 405 | $params['openid.return_to'] = urlencode($this->URLs['approved']); |
| 406 | 406 | $params['openid.mode'] = 'checkid_setup'; |
@@ -422,7 +422,7 @@ discard block |
||
| 422 | 422 | return $this->URLs['openid_server'] . "?" . $this->array2url($params); |
| 423 | 423 | } |
| 424 | 424 | |
| 425 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 425 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 426 | 426 | /** |
| 427 | 427 | * Redirect |
| 428 | 428 | * |
@@ -430,7 +430,7 @@ discard block |
||
| 430 | 430 | */ |
| 431 | 431 | public function Redirect() |
| 432 | 432 | { |
| 433 | - // phpcs:enable |
|
| 433 | + // phpcs:enable |
|
| 434 | 434 | $redirect_to = $this->GetRedirectURL(); |
| 435 | 435 | if (headers_sent()) { // Use JavaScript to redirect if content has been previously sent (not recommended, but safe) |
| 436 | 436 | echo '<script nonce="' . getNonce() . '" type="text/javascript">window.location=\''; |
@@ -441,7 +441,7 @@ discard block |
||
| 441 | 441 | } |
| 442 | 442 | } |
| 443 | 443 | |
| 444 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 444 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 445 | 445 | /** |
| 446 | 446 | * ValidateWithServer |
| 447 | 447 | * |
@@ -449,7 +449,7 @@ discard block |
||
| 449 | 449 | */ |
| 450 | 450 | public function ValidateWithServer() |
| 451 | 451 | { |
| 452 | - // phpcs:enable |
|
| 452 | + // phpcs:enable |
|
| 453 | 453 | $params = array( |
| 454 | 454 | 'openid.assoc_handle' => urlencode($_GET['openid_assoc_handle']), |
| 455 | 455 | 'openid.signed' => urlencode($_GET['openid_signed']), |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | $this->liste = array_merge($array_start, $array_new, $array_end); |
| 104 | 104 | } |
| 105 | 105 | |
| 106 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 106 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 107 | 107 | /** |
| 108 | 108 | * Remove a menu entry from this->liste |
| 109 | 109 | * |
@@ -111,7 +111,7 @@ discard block |
||
| 111 | 111 | */ |
| 112 | 112 | public function remove_last() |
| 113 | 113 | { |
| 114 | - // phpcs:enable |
|
| 114 | + // phpcs:enable |
|
| 115 | 115 | if (count($this->liste) > 1) { |
| 116 | 116 | array_pop($this->liste); |
| 117 | 117 | } |
@@ -1337,7 +1337,7 @@ discard block |
||
| 1337 | 1337 | return '=?' . $conf->file->character_set_client . '?B?' . base64_encode($stringtoencode) . '?='; |
| 1338 | 1338 | } |
| 1339 | 1339 | |
| 1340 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1340 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1341 | 1341 | /** |
| 1342 | 1342 | * Read a file on disk and return encoded content for emails (mode = 'mail') |
| 1343 | 1343 | * |
@@ -1346,7 +1346,7 @@ discard block |
||
| 1346 | 1346 | */ |
| 1347 | 1347 | private function _encode_file($sourcefile) |
| 1348 | 1348 | { |
| 1349 | - // phpcs:enable |
|
| 1349 | + // phpcs:enable |
|
| 1350 | 1350 | $newsourcefile = dol_osencode($sourcefile); |
| 1351 | 1351 | |
| 1352 | 1352 | if (is_readable($newsourcefile)) { |
@@ -1361,7 +1361,7 @@ discard block |
||
| 1361 | 1361 | } |
| 1362 | 1362 | |
| 1363 | 1363 | |
| 1364 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1364 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1365 | 1365 | /** |
| 1366 | 1366 | * Write content of a SMTP request into a dump file (mode = all) |
| 1367 | 1367 | * Used for debugging. |
@@ -1371,7 +1371,7 @@ discard block |
||
| 1371 | 1371 | */ |
| 1372 | 1372 | public function dump_mail() |
| 1373 | 1373 | { |
| 1374 | - // phpcs:enable |
|
| 1374 | + // phpcs:enable |
|
| 1375 | 1375 | global $dolibarr_main_data_root; |
| 1376 | 1376 | |
| 1377 | 1377 | if (@is_writable($dolibarr_main_data_root)) { // Avoid fatal error on fopen with open_basedir |
@@ -1402,7 +1402,7 @@ discard block |
||
| 1402 | 1402 | } |
| 1403 | 1403 | } |
| 1404 | 1404 | |
| 1405 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1405 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1406 | 1406 | /** |
| 1407 | 1407 | * Save content if mail is in error |
| 1408 | 1408 | * Used for debugging. |
@@ -1499,7 +1499,7 @@ discard block |
||
| 1499 | 1499 | } |
| 1500 | 1500 | |
| 1501 | 1501 | |
| 1502 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1502 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1503 | 1503 | /** |
| 1504 | 1504 | * Create SMTP headers (mode = 'mail') |
| 1505 | 1505 | * |
@@ -1507,7 +1507,7 @@ discard block |
||
| 1507 | 1507 | */ |
| 1508 | 1508 | public function write_smtpheaders() |
| 1509 | 1509 | { |
| 1510 | - // phpcs:enable |
|
| 1510 | + // phpcs:enable |
|
| 1511 | 1511 | $out = ""; |
| 1512 | 1512 | $host = dol_getprefix('email'); |
| 1513 | 1513 | |
@@ -1571,7 +1571,7 @@ discard block |
||
| 1571 | 1571 | } |
| 1572 | 1572 | |
| 1573 | 1573 | |
| 1574 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1574 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1575 | 1575 | /** |
| 1576 | 1576 | * Create header MIME (mode = 'mail') |
| 1577 | 1577 | * |
@@ -1581,7 +1581,7 @@ discard block |
||
| 1581 | 1581 | */ |
| 1582 | 1582 | public function write_mimeheaders($filename_list, $mimefilename_list) |
| 1583 | 1583 | { |
| 1584 | - // phpcs:enable |
|
| 1584 | + // phpcs:enable |
|
| 1585 | 1585 | $mimedone = 0; |
| 1586 | 1586 | $out = ""; |
| 1587 | 1587 | |
@@ -1601,7 +1601,7 @@ discard block |
||
| 1601 | 1601 | return $out; |
| 1602 | 1602 | } |
| 1603 | 1603 | |
| 1604 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1604 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1605 | 1605 | /** |
| 1606 | 1606 | * Return email content (mode = 'mail') |
| 1607 | 1607 | * |
@@ -1610,7 +1610,7 @@ discard block |
||
| 1610 | 1610 | */ |
| 1611 | 1611 | public function write_body($msgtext) |
| 1612 | 1612 | { |
| 1613 | - // phpcs:enable |
|
| 1613 | + // phpcs:enable |
|
| 1614 | 1614 | global $conf; |
| 1615 | 1615 | |
| 1616 | 1616 | $out = ''; |
@@ -1694,7 +1694,7 @@ discard block |
||
| 1694 | 1694 | return $out; |
| 1695 | 1695 | } |
| 1696 | 1696 | |
| 1697 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1697 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1698 | 1698 | /** |
| 1699 | 1699 | * Attach file to email (mode = 'mail') |
| 1700 | 1700 | * |
@@ -1706,7 +1706,7 @@ discard block |
||
| 1706 | 1706 | */ |
| 1707 | 1707 | private function write_files($filename_list, $mimetype_list, $mimefilename_list, $cidlist) |
| 1708 | 1708 | { |
| 1709 | - // phpcs:enable |
|
| 1709 | + // phpcs:enable |
|
| 1710 | 1710 | $out = ''; |
| 1711 | 1711 | |
| 1712 | 1712 | $filename_list_size = count($filename_list); |
@@ -1745,7 +1745,7 @@ discard block |
||
| 1745 | 1745 | } |
| 1746 | 1746 | |
| 1747 | 1747 | |
| 1748 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1748 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1749 | 1749 | /** |
| 1750 | 1750 | * Attach an image to email (mode = 'mail') |
| 1751 | 1751 | * |
@@ -1754,7 +1754,7 @@ discard block |
||
| 1754 | 1754 | */ |
| 1755 | 1755 | public function write_images($images_list) |
| 1756 | 1756 | { |
| 1757 | - // phpcs:enable |
|
| 1757 | + // phpcs:enable |
|
| 1758 | 1758 | $out = ''; |
| 1759 | 1759 | |
| 1760 | 1760 | if (is_array($images_list)) { |
@@ -1776,7 +1776,7 @@ discard block |
||
| 1776 | 1776 | } |
| 1777 | 1777 | |
| 1778 | 1778 | |
| 1779 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1779 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1780 | 1780 | /** |
| 1781 | 1781 | * Try to create a socket connection |
| 1782 | 1782 | * |
@@ -1786,7 +1786,7 @@ discard block |
||
| 1786 | 1786 | */ |
| 1787 | 1787 | public function check_server_port($host, $port) |
| 1788 | 1788 | { |
| 1789 | - // phpcs:enable |
|
| 1789 | + // phpcs:enable |
|
| 1790 | 1790 | global $conf; |
| 1791 | 1791 | |
| 1792 | 1792 | $_retVal = 0; |
@@ -1857,7 +1857,7 @@ discard block |
||
| 1857 | 1857 | return $_retVal; |
| 1858 | 1858 | } |
| 1859 | 1859 | |
| 1860 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1860 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 1861 | 1861 | /** |
| 1862 | 1862 | * This function has been modified as provided by SirSir to allow multiline responses when |
| 1863 | 1863 | * using SMTP Extensions. |
@@ -1868,7 +1868,7 @@ discard block |
||
| 1868 | 1868 | */ |
| 1869 | 1869 | public function server_parse($socket, $response) |
| 1870 | 1870 | { |
| 1871 | - // phpcs:enable |
|
| 1871 | + // phpcs:enable |
|
| 1872 | 1872 | $_retVal = true; // Indicates if Object was created or not |
| 1873 | 1873 | $server_response = ''; |
| 1874 | 1874 | |
@@ -350,7 +350,7 @@ discard block |
||
| 350 | 350 | } |
| 351 | 351 | } |
| 352 | 352 | if ($emailtoadd && preg_match('/' . preg_quote($emailtoadd, '/') . '/i', $to)) { |
| 353 | - $emailtoadd = ''; // Email already in the "To" |
|
| 353 | + $emailtoadd = ''; // Email already in the "To" |
|
| 354 | 354 | } |
| 355 | 355 | if ($emailtoadd) { |
| 356 | 356 | $listofemailstoadd[$key] = $emailtoadd; |
@@ -1107,8 +1107,8 @@ discard block |
||
| 1107 | 1107 | } |
| 1108 | 1108 | |
| 1109 | 1109 | $smtperrorcode = 0; |
| 1110 | - if (! $result) { |
|
| 1111 | - $smtperrorcode = $this->smtps->lastretval; // SMTP error code |
|
| 1110 | + if (!$result) { |
|
| 1111 | + $smtperrorcode = $this->smtps->lastretval; // SMTP error code |
|
| 1112 | 1112 | dol_syslog("CMailFile::sendfile: mail SMTP error code " . $smtperrorcode, LOG_WARNING); |
| 1113 | 1113 | |
| 1114 | 1114 | if ($smtperrorcode == '421') { // Try later |
@@ -1126,10 +1126,10 @@ discard block |
||
| 1126 | 1126 | } |
| 1127 | 1127 | } |
| 1128 | 1128 | |
| 1129 | - $result = $this->smtps->getErrors(); // applicative error code (not SMTP error code) |
|
| 1129 | + $result = $this->smtps->getErrors(); // applicative error code (not SMTP error code) |
|
| 1130 | 1130 | if (empty($this->error) && empty($result)) { |
| 1131 | 1131 | dol_syslog("CMailFile::sendfile: mail end success", LOG_DEBUG); |
| 1132 | - $res = true; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 1132 | + $res = true; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 1133 | 1133 | } else { |
| 1134 | 1134 | if (empty($this->error)) { |
| 1135 | 1135 | $this->error = $result; |
@@ -1376,7 +1376,7 @@ discard block |
||
| 1376 | 1376 | |
| 1377 | 1377 | if (@is_writable($dolibarr_main_data_root)) { // Avoid fatal error on fopen with open_basedir |
| 1378 | 1378 | $outputfile = $dolibarr_main_data_root . "/dolibarr_mail.log"; |
| 1379 | - $fp = fopen($outputfile, "w"); // overwrite |
|
| 1379 | + $fp = fopen($outputfile, "w"); // overwrite |
|
| 1380 | 1380 | |
| 1381 | 1381 | if ($this->sendmode == 'mail') { |
| 1382 | 1382 | fwrite($fp, $this->headers); |
@@ -1634,7 +1634,7 @@ discard block |
||
| 1634 | 1634 | // Similar code to forge a text from html is also in smtps.class.php |
| 1635 | 1635 | $strContentAltText = preg_replace("/<br\s*[^>]*>/", " ", $strContent); |
| 1636 | 1636 | // TODO We could replace <img ...> with [Filename.ext] like Gmail do. |
| 1637 | - $strContentAltText = html_entity_decode(strip_tags($strContentAltText)); // Remove any HTML tags |
|
| 1637 | + $strContentAltText = html_entity_decode(strip_tags($strContentAltText)); // Remove any HTML tags |
|
| 1638 | 1638 | $strContentAltText = trim(wordwrap($strContentAltText, 75, !getDolGlobalString('MAIN_FIX_FOR_BUGGED_MTA') ? "\r\n" : "\n")); |
| 1639 | 1639 | |
| 1640 | 1640 | // Check if html header already in message, if not complete the message |
@@ -2019,7 +2019,7 @@ discard block |
||
| 2019 | 2019 | // We save the image to send in disk |
| 2020 | 2020 | $filecontent = $matches[2][$key]; |
| 2021 | 2021 | |
| 2022 | - $cid = 'cid000' . dol_hash($filecontent, 'md5'); // The id must not change if image is same |
|
| 2022 | + $cid = 'cid000' . dol_hash($filecontent, 'md5'); // The id must not change if image is same |
|
| 2023 | 2023 | |
| 2024 | 2024 | $destfiletmp = $images_dir . '/' . $cid . '.' . $ext; |
| 2025 | 2025 | |
@@ -112,7 +112,7 @@ discard block |
||
| 112 | 112 | } |
| 113 | 113 | |
| 114 | 114 | |
| 115 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 115 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 116 | 116 | /** |
| 117 | 117 | * Function to build pdf onto disk |
| 118 | 118 | * |
@@ -126,7 +126,7 @@ discard block |
||
| 126 | 126 | */ |
| 127 | 127 | public function write_file($object, $outputlangs, $srctemplatepath = '', $hidedetails = 0, $hidedesc = 0, $hideref = 0) |
| 128 | 128 | { |
| 129 | - // phpcs:enable |
|
| 129 | + // phpcs:enable |
|
| 130 | 130 | global $user, $langs, $conf, $mysoc, $hookmanager; |
| 131 | 131 | |
| 132 | 132 | if (!is_object($outputlangs)) { |
@@ -594,8 +594,8 @@ discard block |
||
| 594 | 594 | return 0; |
| 595 | 595 | } |
| 596 | 596 | |
| 597 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 598 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 597 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 598 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 599 | 599 | /** |
| 600 | 600 | * Show miscellaneous information (payment mode, payment term, ...) |
| 601 | 601 | * |
@@ -607,7 +607,7 @@ discard block |
||
| 607 | 607 | */ |
| 608 | 608 | protected function _tableau_info(&$pdf, $object, $posy, $outputlangs) |
| 609 | 609 | { |
| 610 | - // phpcs:enable |
|
| 610 | + // phpcs:enable |
|
| 611 | 611 | global $conf, $mysoc; |
| 612 | 612 | $default_font_size = pdf_getPDFFontSize($outputlangs); |
| 613 | 613 | |
@@ -625,7 +625,7 @@ discard block |
||
| 625 | 625 | } |
| 626 | 626 | |
| 627 | 627 | |
| 628 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 628 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 629 | 629 | /** |
| 630 | 630 | * Show table for lines |
| 631 | 631 | * |
@@ -675,7 +675,7 @@ discard block |
||
| 675 | 675 | } |
| 676 | 676 | } |
| 677 | 677 | |
| 678 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 678 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 679 | 679 | /** |
| 680 | 680 | * Show top header of page. |
| 681 | 681 | * |
@@ -853,7 +853,7 @@ discard block |
||
| 853 | 853 | return 0; |
| 854 | 854 | } |
| 855 | 855 | |
| 856 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 856 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 857 | 857 | /** |
| 858 | 858 | * Show footer of page. Need this->emetteur object |
| 859 | 859 | * |
@@ -822,7 +822,7 @@ |
||
| 822 | 822 | if ($this->page_largeur < 210) { |
| 823 | 823 | $widthrecbox = 84; // To work with US executive format |
| 824 | 824 | } |
| 825 | - $posy = 42; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 825 | + $posy = 42; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 826 | 826 | $posx = $this->page_largeur - $this->marge_droite - $widthrecbox; |
| 827 | 827 | if (getDolGlobalString('MAIN_INVERT_SENDER_RECIPIENT')) { |
| 828 | 828 | $posx = $this->marge_gauche; |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | } |
| 134 | 134 | |
| 135 | 135 | |
| 136 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 136 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 137 | 137 | /** |
| 138 | 138 | * Function to build pdf onto disk |
| 139 | 139 | * |
@@ -147,7 +147,7 @@ discard block |
||
| 147 | 147 | */ |
| 148 | 148 | public function write_file($object, $outputlangs, $srctemplatepath = '', $hidedetails = 0, $hidedesc = 0, $hideref = 0) |
| 149 | 149 | { |
| 150 | - // phpcs:enable |
|
| 150 | + // phpcs:enable |
|
| 151 | 151 | global $user, $langs, $conf, $mysoc, $hookmanager; |
| 152 | 152 | |
| 153 | 153 | if (!is_object($outputlangs)) { |
@@ -587,8 +587,8 @@ discard block |
||
| 587 | 587 | return 0; |
| 588 | 588 | } |
| 589 | 589 | |
| 590 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 591 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 590 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 591 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 592 | 592 | /** |
| 593 | 593 | * Show miscellaneous information (payment mode, payment term, ...) |
| 594 | 594 | * |
@@ -600,7 +600,7 @@ discard block |
||
| 600 | 600 | */ |
| 601 | 601 | protected function _tableau_info(&$pdf, $object, $posy, $outputlangs) |
| 602 | 602 | { |
| 603 | - // phpcs:enable |
|
| 603 | + // phpcs:enable |
|
| 604 | 604 | global $conf, $mysoc; |
| 605 | 605 | $default_font_size = pdf_getPDFFontSize($outputlangs); |
| 606 | 606 | |
@@ -617,7 +617,7 @@ discard block |
||
| 617 | 617 | $pdf->MultiCell($larg_sign, 2, $outputlangs->trans("ForCustomer") . ':', '', 'L'); |
| 618 | 618 | } |
| 619 | 619 | |
| 620 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 620 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 621 | 621 | /** |
| 622 | 622 | * Show table for lines |
| 623 | 623 | * |
@@ -683,7 +683,7 @@ discard block |
||
| 683 | 683 | } |
| 684 | 684 | } |
| 685 | 685 | |
| 686 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 686 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 687 | 687 | /** |
| 688 | 688 | * Show top header of page. |
| 689 | 689 | * |
@@ -861,7 +861,7 @@ discard block |
||
| 861 | 861 | return 0; |
| 862 | 862 | } |
| 863 | 863 | |
| 864 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 864 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 865 | 865 | /** |
| 866 | 866 | * Show footer of page. Need this->emetteur object |
| 867 | 867 | * |
@@ -71,8 +71,8 @@ discard block |
||
| 71 | 71 | */ |
| 72 | 72 | public $version = 'dolibarr'; |
| 73 | 73 | |
| 74 | - public $posxcomm; // For customer comment column |
|
| 75 | - public $posxweightvol; // For weight or volume |
|
| 74 | + public $posxcomm; // For customer comment column |
|
| 75 | + public $posxweightvol; // For weight or volume |
|
| 76 | 76 | public $posxremainingqty; |
| 77 | 77 | |
| 78 | 78 | |
@@ -115,7 +115,7 @@ discard block |
||
| 115 | 115 | |
| 116 | 116 | // Define position of columns |
| 117 | 117 | $this->posxdesc = $this->marge_gauche + 1; |
| 118 | - $this->posxcomm = 112; // customer comment |
|
| 118 | + $this->posxcomm = 112; // customer comment |
|
| 119 | 119 | //$this->posxtva=112; |
| 120 | 120 | //$this->posxup=126; |
| 121 | 121 | $this->posxqty = 165; |
@@ -830,7 +830,7 @@ discard block |
||
| 830 | 830 | if ($this->page_largeur < 210) { |
| 831 | 831 | $widthrecbox = 84; // To work with US executive format |
| 832 | 832 | } |
| 833 | - $posy = 42; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 833 | + $posy = 42; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 834 | 834 | $posx = $this->page_largeur - $this->marge_droite - $widthrecbox; |
| 835 | 835 | if (getDolGlobalString('MAIN_INVERT_SENDER_RECIPIENT')) { |
| 836 | 836 | $posx = $this->marge_gauche; |
@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | */ |
| 39 | 39 | abstract class ModelePDFDeliveryOrder extends CommonDocGenerator |
| 40 | 40 | { |
| 41 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 41 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 42 | 42 | /** |
| 43 | 43 | * Return list of active generation modules |
| 44 | 44 | * |
@@ -48,7 +48,7 @@ discard block |
||
| 48 | 48 | */ |
| 49 | 49 | public static function liste_modeles($db, $maxfilenamelength = 0) |
| 50 | 50 | { |
| 51 | - // phpcs:enable |
|
| 51 | + // phpcs:enable |
|
| 52 | 52 | $type = 'delivery'; |
| 53 | 53 | $list = array(); |
| 54 | 54 | |