Passed
Push — master ( 6894ed...3cfcb2 )
by Daniel
02:29
created
source/DomComponentsByDanielGP.php 1 patch
Spacing   +93 added lines, -93 removed lines patch added patch discarded remove patch
@@ -62,13 +62,13 @@  discard block
 block discarded – undo
62 62
                         $ditTitle .= ' (0)';
63 63
                     }
64 64
                     $divTab = [
65
-                        'start' => '<div class="tabbertab tabbertabdefault" id="tab_NoData" title="' . $ditTitle . '">',
65
+                        'start' => '<div class="tabbertab tabbertabdefault" id="tab_NoData" title="'.$ditTitle.'">',
66 66
                         'end'   => '</div><!-- from tab_NoData -->',
67 67
                     ];
68 68
                     if (!isset($ftrs['noGlobalTab'])) {
69 69
                         $divTab = [
70
-                            'start' => '<div class="tabber" id="tab">' . $divTab['start'],
71
-                            'end'   => $divTab['end'] . '</div><!-- from global Tab -->',
70
+                            'start' => '<div class="tabber" id="tab">'.$divTab['start'],
71
+                            'end'   => $divTab['end'].'</div><!-- from global Tab -->',
72 72
                         ];
73 73
                     }
74 74
                 }
@@ -91,14 +91,14 @@  discard block
 block discarded – undo
91 91
         }
92 92
         $checkboxFormId = '';
93 93
         if ((isset($ftrs['actions']['checkbox_inlineEdit'])) || (isset($ftrs['actions']['checkbox']))) {
94
-            $checkboxFormId = 'frm' . date('YmdHis');
95
-            $sReturn        .= '<form id="' . $checkboxFormId . '" name="' . $checkboxFormId
96
-                . '" method="post" ' . ' action="' . $this->tCmnRequest->server->get('PHP_SELF') . '" >';
94
+            $checkboxFormId = 'frm'.date('YmdHis');
95
+            $sReturn .= '<form id="'.$checkboxFormId.'" name="'.$checkboxFormId
96
+                . '" method="post" '.' action="'.$this->tCmnRequest->server->get('PHP_SELF').'" >';
97 97
         }
98 98
         $tbl        = [];
99 99
         $tbl['Def'] = '<table'
100
-            . (isset($ftrs['table_style']) ? ' style="' . $ftrs['table_style'] . '"' : '')
101
-            . (isset($ftrs['table_class']) ? ' class="' . $ftrs['table_class'] . '"' : '')
100
+            . (isset($ftrs['table_style']) ? ' style="'.$ftrs['table_style'].'"' : '')
101
+            . (isset($ftrs['table_class']) ? ' class="'.$ftrs['table_class'].'"' : '')
102 102
             . '>';
103 103
         if (!isset($ftrs['grouping_cell_type'])) {
104 104
             $ftrs['grouping_cell_type'] = 'row';
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
                     $sReturn .= $tbl['Head'];
140 140
                 }
141 141
                 if (isset($iStartingPageRecord)) {
142
-                    $pgn     = $this->setPagination($ftrs['limits'][0], $ftrs['limits'][1], $ftrs['limits'][2], $bKpFlPge);
142
+                    $pgn = $this->setPagination($ftrs['limits'][0], $ftrs['limits'][1], $ftrs['limits'][2], $bKpFlPge);
143 143
                     $sReturn .= $this->setStringIntoTag($this->setStringIntoTag($pgn, 'th', [
144 144
                             'colspan' => $iTableColumns
145 145
                         ]), 'tr');
@@ -181,22 +181,22 @@  discard block
 block discarded – undo
181 181
                     }
182 182
                     $remebered_value = $color_column_value;
183 183
                 }
184
-                $color = ' style="background-color: ' . $ftrs['row_colored_alternated'][$color_no] . ';"';
184
+                $color = ' style="background-color: '.$ftrs['row_colored_alternated'][$color_no].';"';
185 185
             } else {
186 186
                 if (isset($ftrs['RowStyle'])) {
187
-                    $color = ' style="' . $aElements[$rCntr][$ftrs['RowStyle']] . '"';
187
+                    $color = ' style="'.$aElements[$rCntr][$ftrs['RowStyle']].'"';
188 188
                 } else {
189 189
                     $color = '';
190 190
                 }
191 191
             }
192
-            $tbl['tr_Color'] = '<tr' . $color . '>';
192
+            $tbl['tr_Color'] = '<tr'.$color.'>';
193 193
 // Grouping column
194 194
             if (isset($ftrs['grouping_cell'])) {
195 195
                 foreach ($aElements[$rCntr] as $key => $value) {
196 196
                     if (($ftrs['grouping_cell'] == $key) && ($remindGroupValue != $value)) {
197 197
                         switch ($ftrs['grouping_cell_type']) {
198 198
                             case 'row':
199
-                                $sReturn .= $tbl['tr_Color'] . '<td ' . 'colspan="' . $iTableColumns . '">'
199
+                                $sReturn .= $tbl['tr_Color'].'<td '.'colspan="'.$iTableColumns.'">'
200 200
                                     . $this->setStringIntoTag($value, 'div', ['class' => 'rowGroup rounded'])
201 201
                                     . '</td></tr>';
202 202
                                 break;
@@ -208,7 +208,7 @@  discard block
 block discarded – undo
208 208
                                 } else {
209 209
                                     $sReturn .= '</tbody></table>';
210 210
                                     if (isset($ftrs['showGroupingCounter'])) {
211
-                                        $sReturn      .= $this->updateDivTitleName($remindGroupValue, $groupCounter);
211
+                                        $sReturn .= $this->updateDivTitleName($remindGroupValue, $groupCounter);
212 212
                                         $groupCounter = 0;
213 213
                                     }
214 214
                                     $sReturn .= '</div>';
@@ -217,9 +217,9 @@  discard block
 block discarded – undo
217 217
                                 if (isset($ftrs['grouping_default_tab'])) {
218 218
                                     $sReturn .= ($ftrs['grouping_default_tab'] == $value ? ' tabbertabdefault' : '');
219 219
                                 }
220
-                                $sReturn .= '" id="tab_' . $this->cleanStringForId($value) . '" '
221
-                                    . 'title="' . $value . '">'
222
-                                    . $tbl['Def'] . $tbl['Head'] . $tbl['Header'];
220
+                                $sReturn .= '" id="tab_'.$this->cleanStringForId($value).'" '
221
+                                    . 'title="'.$value.'">'
222
+                                    . $tbl['Def'].$tbl['Head'].$tbl['Header'];
223 223
                                 break;
224 224
                         }
225 225
                         $remindGroupValue = $value;
@@ -233,12 +233,12 @@  discard block
 block discarded – undo
233 233
                     }
234 234
                 }
235 235
             }
236
-            $sReturn       .= $tbl['tr_Color'];
236
+            $sReturn .= $tbl['tr_Color'];
237 237
 // Action column
238 238
             $checkboxName  = '';
239 239
             $checkboxNameS = '';
240 240
             if (isset($ftrs['actions'])) {
241
-                $sReturn         .= '<td style="white-space:nowrap;">';
241
+                $sReturn .= '<td style="white-space:nowrap;">';
242 242
                 $action_argument = 0;
243 243
                 if (isset($ftrs['actions']['key'])) {
244 244
                     $actionKey = $ftrs['actions']['key'];
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
                     $actionKey = 'view';
247 247
                 }
248 248
                 if (isset($ftrs['action_prefix'])) {
249
-                    $actPrfx   = $ftrs['action_prefix'] . '&amp;';
249
+                    $actPrfx   = $ftrs['action_prefix'].'&amp;';
250 250
                     $actionKey = 'view2';
251 251
                 } else {
252 252
                     $actPrfx = '';
@@ -257,11 +257,11 @@  discard block
 block discarded – undo
257 257
                     }
258 258
                     switch ($key) {
259 259
                         case 'checkbox':
260
-                            $checkboxName  = $value . '[]';
260
+                            $checkboxName  = $value.'[]';
261 261
                             $checkboxNameS = $value;
262
-                            $sReturn       .= '&nbsp;<input type="checkbox" name="' . $checkboxName
263
-                                . '" id="n' . $aElements[$rCntr][$value]
264
-                                . '" value="' . $aElements[$rCntr][$value] . '" ';
262
+                            $sReturn .= '&nbsp;<input type="checkbox" name="'.$checkboxName
263
+                                . '" id="n'.$aElements[$rCntr][$value]
264
+                                . '" value="'.$aElements[$rCntr][$value].'" ';
265 265
                             if (isset($_REQUEST[$checkboxNameS])) {
266 266
                                 if (is_array($_REQUEST[$checkboxNameS])) {
267 267
                                     if (in_array($aElements[$rCntr][$value], $_REQUEST[$checkboxNameS])) {
@@ -276,29 +276,29 @@  discard block
 block discarded – undo
276 276
                             if (strpos($_REQUEST['view'], 'multiEdit') !== false) {
277 277
                                 $sReturn .= 'disabled="disabled" ';
278 278
                             }
279
-                            $sReturn       .= '/>';
279
+                            $sReturn .= '/>';
280 280
                             break;
281 281
                         case 'checkbox_inlineEdit':
282
-                            $checkboxName  = $value . '[]';
282
+                            $checkboxName  = $value.'[]';
283 283
                             $checkboxNameS = $value;
284
-                            $sReturn       .= '&nbsp;<input type="checkbox" name="' . $checkboxName
285
-                                . '" id="n' . $aElements[$rCntr][$value] . '" value="'
286
-                                . $aElements[$rCntr][$value] . '"/>';
284
+                            $sReturn .= '&nbsp;<input type="checkbox" name="'.$checkboxName
285
+                                . '" id="n'.$aElements[$rCntr][$value].'" value="'
286
+                                . $aElements[$rCntr][$value].'"/>';
287 287
                             break;
288 288
                         case 'delete':
289
-                            $sReturn       .= '<a href="#" onclick="javascript:setQuest(\'' . $value[0] . '\',\'';
290
-                            $iActArgs      = count($value[1]);
289
+                            $sReturn .= '<a href="#" onclick="javascript:setQuest(\''.$value[0].'\',\'';
290
+                            $iActArgs = count($value[1]);
291 291
                             for ($cntr2 = 0; $cntr2 < $iActArgs; $cntr2++) {
292
-                                $sReturn .= $value[1][$cntr2] . '=' . $aElements[$rCntr][$value[1][$cntr2]];
292
+                                $sReturn .= $value[1][$cntr2].'='.$aElements[$rCntr][$value[1][$cntr2]];
293 293
                             }
294
-                            $sReturn .= '\');" id="' . $key . $rCntr . '"><i class="fa fa-times">&nbsp;</i></a>';
294
+                            $sReturn .= '\');" id="'.$key.$rCntr.'"><i class="fa fa-times">&nbsp;</i></a>';
295 295
                             break;
296 296
                         case 'edit':
297 297
                         case 'list2':
298 298
                         case 'schedule':
299
-                            $vIc     = ($key == 'edit' ? 'pencil' : ($key == 'list2' ? 'list' : 'hourglass-half'));
299
+                            $vIc = ($key == 'edit' ? 'pencil' : ($key == 'list2' ? 'list' : 'hourglass-half'));
300 300
                             $sReturn .= $this->setDynamicActionToSpecialCell($value, $aElements, [
301
-                                'vIcon'    => 'fa fa-' . $vIc,
301
+                                'vIcon'    => 'fa fa-'.$vIc,
302 302
                                 'aPrefix'  => $actPrfx,
303 303
                                 'aKey'     => $actionKey,
304 304
                                 'rCounter' => $rCntr,
@@ -326,7 +326,7 @@  discard block
 block discarded – undo
326 326
                     switch ($value[1]) {
327 327
                         case '/':
328 328
                             // next variable is only to avoid a long line
329
-                            $shorter                 = [
329
+                            $shorter = [
330 330
                                 $aElements[$rCntr][$value[3]],
331 331
                                 $aElements[$rCntr][$value[4]],
332 332
                             ];
@@ -334,7 +334,7 @@  discard block
 block discarded – undo
334 334
                             break;
335 335
                         case '+':
336 336
                             // next variable is only to avoid a long line
337
-                            $iTemp                   = $this->setArrayValuesAsKey([
337
+                            $iTemp = $this->setArrayValuesAsKey([
338 338
                                 $value[0],
339 339
                                 $value[1],
340 340
                                 $value[2]
@@ -351,7 +351,7 @@  discard block
 block discarded – undo
351 351
                     }
352 352
                     if ($value[0] == '%') {
353 353
                         $rowComputed[$key] = ($aElements[$rCntr][$key] * 100);
354
-                        $dec               -= 2;
354
+                        $dec -= 2;
355 355
                     } else {
356 356
                         $rowComputed[$key] = $aElements[$rCntr][$key];
357 357
                     }
@@ -363,59 +363,59 @@  discard block
 block discarded – undo
363 363
             $sReturn .= '</tr>';
364 364
         }
365 365
         if (isset($iStartingPageRecord)) {
366
-            $pgn     = $this->setPagination($ftrs['limits'][0], $ftrs['limits'][1], $ftrs['limits'][2]);
367
-            $sReturn .= '<tr>' . $this->setStringIntoTag($pgn, 'th', ['colspan' => $iTableColumns]) . '</tr>';
366
+            $pgn = $this->setPagination($ftrs['limits'][0], $ftrs['limits'][1], $ftrs['limits'][2]);
367
+            $sReturn .= '<tr>'.$this->setStringIntoTag($pgn, 'th', ['colspan' => $iTableColumns]).'</tr>';
368 368
         }
369 369
         $sReturn .= '</tbody></table>';
370 370
         if ($ftrs['grouping_cell_type'] == 'tab') {
371 371
             if (isset($ftrs['showGroupingCounter'])) {
372 372
                 $sReturn .= $this->updateDivTitleName($remindGroupValue, $groupCounter);
373 373
             }
374
-            $sReturn .= '</div><!-- from ' . $remindGroupValue . ' -->';
374
+            $sReturn .= '</div><!-- from '.$remindGroupValue.' -->';
375 375
             if (!isset($ftrs['noGlobalTab'])) {
376 376
                 $sReturn .= '</div><!-- from global tab -->';
377 377
             }
378 378
         }
379 379
         if (isset($ftrs['actions']['checkbox'])) {
380 380
             if (strpos($_REQUEST['view'], 'multiEdit') === false) {
381
-                $sReturn .= '<a href="#" onclick="javascript:checking(\'' . $checkboxFormId
382
-                    . '\',\'' . $checkboxName . '\',true);">Check All</a>&nbsp;&nbsp;'
383
-                    . '<a href="#" onclick="javascript:checking(\'' . $checkboxFormId
384
-                    . '\',\'' . $checkboxName . '\',false);">Uncheck All</a>&nbsp;&nbsp;'
385
-                    . '<input type="hidden" name="action" value="multiEdit_' . $checkboxNameS . '" />';
381
+                $sReturn .= '<a href="#" onclick="javascript:checking(\''.$checkboxFormId
382
+                    . '\',\''.$checkboxName.'\',true);">Check All</a>&nbsp;&nbsp;'
383
+                    . '<a href="#" onclick="javascript:checking(\''.$checkboxFormId
384
+                    . '\',\''.$checkboxName.'\',false);">Uncheck All</a>&nbsp;&nbsp;'
385
+                    . '<input type="hidden" name="action" value="multiEdit_'.$checkboxNameS.'" />';
386 386
                 if (isset($ftrs['hiddenInput'])) {
387 387
                     if (is_array($ftrs['hiddenInput'])) {
388 388
                         foreach ($ftrs['hiddenInput'] as $valueF) {
389
-                            $sReturn .= '<input type="hidden" name="' . $valueF
390
-                                . '" value="' . $_REQUEST[$valueF] . '" />';
389
+                            $sReturn .= '<input type="hidden" name="'.$valueF
390
+                                . '" value="'.$_REQUEST[$valueF].'" />';
391 391
                         }
392 392
                     } else {
393
-                        $sReturn .= '<input type="hidden" name="' . $ftrs['hiddenInput']
394
-                            . '" value="' . $_REQUEST[$ftrs['hiddenInput']] . '" />';
393
+                        $sReturn .= '<input type="hidden" name="'.$ftrs['hiddenInput']
394
+                            . '" value="'.$_REQUEST[$ftrs['hiddenInput']].'" />';
395 395
                     }
396 396
                 }
397
-                $sReturn .= '<input style="margin: 0 3em 0 3em;" type="submit" ' . 'value="Edit selected" />';
397
+                $sReturn .= '<input style="margin: 0 3em 0 3em;" type="submit" '.'value="Edit selected" />';
398 398
             }
399 399
             $sReturn .= '</form>';
400 400
         }
401 401
         if (isset($ftrs['actions']['checkbox_inlineEdit'])) {
402
-            $sReturn .= '<a href="#" onclick="javascript:checking(\'' . $checkboxFormId
403
-                . '\',\'' . $checkboxName . '\',true);">Check All</a>&nbsp;&nbsp;'
404
-                . '<a href="#" onclick="javascript:checking(\'' . $checkboxFormId
405
-                . '\',\'' . $checkboxName . '\',false);">Uncheck All</a>&nbsp;&nbsp;';
402
+            $sReturn .= '<a href="#" onclick="javascript:checking(\''.$checkboxFormId
403
+                . '\',\''.$checkboxName.'\',true);">Check All</a>&nbsp;&nbsp;'
404
+                . '<a href="#" onclick="javascript:checking(\''.$checkboxFormId
405
+                . '\',\''.$checkboxName.'\',false);">Uncheck All</a>&nbsp;&nbsp;';
406 406
             if (isset($ftrs['visibleInput'])) {
407 407
                 $sReturn .= $ftrs['visibleInput'];
408 408
             }
409
-            $sReturn .= '<input type="hidden" name="view" value="save_' . $checkboxNameS . '" />';
409
+            $sReturn .= '<input type="hidden" name="view" value="save_'.$checkboxNameS.'" />';
410 410
             if (isset($ftrs['hiddenInput'])) {
411 411
                 if (is_array($ftrs['hiddenInput'])) {
412 412
                     foreach ($ftrs['hiddenInput'] as $valueF) {
413
-                        $sReturn .= '<input type="hidden" name="' . $valueF
414
-                            . '" value="' . $_REQUEST[$valueF] . '" />';
413
+                        $sReturn .= '<input type="hidden" name="'.$valueF
414
+                            . '" value="'.$_REQUEST[$valueF].'" />';
415 415
                     }
416 416
                 } else {
417
-                    $sReturn .= '<input type="hidden" name="' . $ftrs['hiddenInput']
418
-                        . '" value="' . $_REQUEST[$ftrs['hiddenInput']] . '" />';
417
+                    $sReturn .= '<input type="hidden" name="'.$ftrs['hiddenInput']
418
+                        . '" value="'.$_REQUEST[$ftrs['hiddenInput']].'" />';
419 419
                 }
420 420
             }
421 421
             $sReturn .= '<input style="margin: 0 3em 0 3em;" type="submit" value="Store the modification" />';
@@ -435,12 +435,12 @@  discard block
 block discarded – undo
435 435
     {
436 436
         return $this->setStringIntoTag('&nbsp;', 'span', [
437 437
                 'onclick' => implode('', [
438
-                    'javascript:NewCssCal(\'' . $controlName,
438
+                    'javascript:NewCssCal(\''.$controlName,
439 439
                     '\',\'yyyyMMdd\',\'dropdown\',false,\'24\',false);',
440 440
                 ]),
441 441
                 'class'   => 'fa fa-calendar',
442
-                'id'      => $controlName . '_picker',
443
-                'style'   => 'cursor:pointer;' . $additionalStyle,
442
+                'id'      => $controlName.'_picker',
443
+                'style'   => 'cursor:pointer;'.$additionalStyle,
444 444
         ]);
445 445
     }
446 446
 
@@ -455,30 +455,30 @@  discard block
 block discarded – undo
455 455
     {
456 456
         return $this->setStringIntoTag('&nbsp;', 'span', [
457 457
                 'onclick' => implode('', [
458
-                    'javascript:NewCssCal(\'' . $controlName,
458
+                    'javascript:NewCssCal(\''.$controlName,
459 459
                     '\',\'yyyyMMdd\',\'dropdown\',true,\'24\',true);',
460 460
                 ]),
461 461
                 'class'   => 'fa fa-calendar',
462
-                'id'      => $controlName . '_picker',
463
-                'style'   => 'cursor:pointer;' . $additionalStyle,
462
+                'id'      => $controlName.'_picker',
463
+                'style'   => 'cursor:pointer;'.$additionalStyle,
464 464
         ]);
465 465
     }
466 466
 
467 467
     private function setDynamicActionToSpecialCell($val, $aElements, $inP)
468 468
     {
469 469
         $aArgumemts   = [];
470
-        $aArgumemts[] = $this->tCmnSuperGlobals->getScriptName() . '?' . $inP['aPrefix'] . $inP['aKey'] . '=' . $val[0];
470
+        $aArgumemts[] = $this->tCmnSuperGlobals->getScriptName().'?'.$inP['aPrefix'].$inP['aKey'].'='.$val[0];
471 471
         $iActArgs     = count($val[1]);
472 472
         for ($counter = 0; $counter < $iActArgs; $counter++) {
473
-            $aArgumemts[] = $val[1][$counter] . '=' . $aElements[$inP['rCounter']][$val[1][$counter]];
473
+            $aArgumemts[] = $val[1][$counter].'='.$aElements[$inP['rCounter']][$val[1][$counter]];
474 474
         }
475
-        $id = $inP['key'] . $inP['rCounter'];
475
+        $id = $inP['key'].$inP['rCounter'];
476 476
         if (isset($inP['Features']['NoAjaxEditing'])) {
477
-            return '<a href="' . implode('&amp;', $aArgumemts) . '" id="' . $id . '"><i class="'
478
-                . $inP['vIcon'] . '">&nbsp;</i></a>';
477
+            return '<a href="'.implode('&amp;', $aArgumemts).'" id="'.$id.'"><i class="'
478
+                . $inP['vIcon'].'">&nbsp;</i></a>';
479 479
         }
480
-        return '<a href="#" onclick="javascript:loadAE(\'' . implode('&amp;', $aArgumemts) . '\');"'
481
-            . ' id="' . $id . '"><i class="' . $inP['vIcon'] . '">&nbsp;</i></a>';
480
+        return '<a href="#" onclick="javascript:loadAE(\''.implode('&amp;', $aArgumemts).'\');"'
481
+            . ' id="'.$id.'"><i class="'.$inP['vIcon'].'">&nbsp;</i></a>';
482 482
     }
483 483
 
484 484
     /**
@@ -493,7 +493,7 @@  discard block
 block discarded – undo
493 493
         if (!is_null($sHK) && (in_array('noHeader', $sHK))) {
494 494
             return '';
495 495
         }
496
-        return $this->setFooterCommonInjected($footerInjected) . '</body></html>';
496
+        return $this->setFooterCommonInjected($footerInjected).'</body></html>';
497 497
     }
498 498
 
499 499
     protected function setFooterCommonInjected($footerInjected = null)
@@ -526,11 +526,11 @@  discard block
 block discarded – undo
526 526
                 'lang'     => '<html lang="en-US">',
527 527
                 'head'     => '<head>',
528 528
                 'charset'  => '<meta charset="utf-8" />',
529
-                'viewport' => '<meta name="viewport" content="' . implode(', ', [
529
+                'viewport' => '<meta name="viewport" content="'.implode(', ', [
530 530
                     'width=device-width',
531 531
                     'height=device-height',
532 532
                     'initial-scale=1',
533
-                ]) . '" />',
533
+                ]).'" />',
534 534
             ];
535 535
             if (!is_null($headerFeatures)) {
536 536
                 if (is_array($headerFeatures)) {
@@ -558,11 +558,11 @@  discard block
 block discarded – undo
558 558
                                 break;
559 559
                             case 'lang':
560 560
                                 $fixedHeaderElements['lang'] = '<html lang="'
561
-                                    . filter_var($value, FILTER_SANITIZE_STRING) . '">';
561
+                                    . filter_var($value, FILTER_SANITIZE_STRING).'">';
562 562
                                 break;
563 563
                             case 'title':
564
-                                $aFeatures[]                 = '<title>'
565
-                                    . filter_var($value, FILTER_SANITIZE_STRING) . '</title>';
564
+                                $aFeatures[] = '<title>'
565
+                                    . filter_var($value, FILTER_SANITIZE_STRING).'</title>';
566 566
                                 break;
567 567
                         }
568 568
                     }
@@ -575,7 +575,7 @@  discard block
 block discarded – undo
575 575
                         . '</head>'
576 576
                         . '<body>'
577 577
                         . '<p style="background-color:red;color:#FFF;">The parameter sent to '
578
-                        . __FUNCTION__ . ' must be an array</p>'
578
+                        . __FUNCTION__.' must be an array</p>'
579 579
                         . $this->setFooterCommon();
580 580
                     throw new \Exception($sReturn);
581 581
                 }
@@ -603,10 +603,10 @@  discard block
 block discarded – undo
603 603
                 if (isset($features['column_formatting'][$key])) {
604 604
                     switch ($features['column_formatting'][$key]) {
605 605
                         case '@':
606
-                            $sReturn .= 'style="text-align:left;">' . $value;
606
+                            $sReturn .= 'style="text-align:left;">'.$value;
607 607
                             break;
608 608
                         case 'right':
609
-                            $sReturn .= 'style="text-align:right;">' . $value;
609
+                            $sReturn .= 'style="text-align:right;">'.$value;
610 610
                             break;
611 611
                         default:
612 612
                             $sReturn .= '???';
@@ -620,12 +620,12 @@  discard block
 block discarded – undo
620 620
                         if ((strpos($value, '-') !== false) && (strlen($value) == 10)) {
621 621
                             if (preg_match("([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})", $value, $regs)) {
622 622
                                 $outputet = true;
623
-                                $sReturn  .= 'style="text-align:right;width: 10px;">'
624
-                                    . $regs[3] . '.' . $regs[2] . '.' . $regs[1];
623
+                                $sReturn .= 'style="text-align:right;width: 10px;">'
624
+                                    . $regs[3].'.'.$regs[2].'.'.$regs[1];
625 625
                             }
626 626
                         }
627 627
                         if (!$outputet) {
628
-                            $sReturn .= 'style="text-align:left;">' . $value;
628
+                            $sReturn .= 'style="text-align:left;">'.$value;
629 629
                         }
630 630
                     }
631 631
                 }
@@ -651,11 +651,11 @@  discard block
 block discarded – undo
651 651
     {
652 652
         $styleToReturn = 'style="text-align: right;">';
653 653
         if (substr($value, 0, 1) === '0') {
654
-            return $styleToReturn . $value;
654
+            return $styleToReturn.$value;
655 655
         }
656 656
         $decimals = $this->setTableCellDecimals($key, $features);
657 657
         $nDc      = ['MinFractionDigits' => $decimals, 'MaxFractionDigits' => $decimals];
658
-        return $styleToReturn . $this->setNumberFormat($value, $nDc);
658
+        return $styleToReturn.$this->setNumberFormat($value, $nDc);
659 659
     }
660 660
 
661 661
     /**
@@ -691,7 +691,7 @@  discard block
 block discarded – undo
691 691
         $this->handleLanguageIntoSession();
692 692
         return '<div class="upperRightBox">'
693 693
             . '<div style="text-align:right;">'
694
-            . '<span class="flag-icon flag-icon-' . strtolower(substr($this->tCmnSession->get('lang'), -2))
694
+            . '<span class="flag-icon flag-icon-'.strtolower(substr($this->tCmnSession->get('lang'), -2))
695 695
             . '" style="margin-right:2px;">&nbsp;</span>'
696 696
             . $aAvailableLanguages[$this->tCmnSession->get('lang')]
697 697
             . '</div><!-- default Language -->'
@@ -704,17 +704,17 @@  discard block
 block discarded – undo
704 704
         $linkWithoutLanguage = '';
705 705
         $alR                 = $this->tCmnSuperGlobals->query->all();
706 706
         if (count($alR) > 0) {
707
-            $linkWithoutLanguage = $this->setArrayToStringForUrl('&amp;', $alR, ['lang']) . '&amp;';
707
+            $linkWithoutLanguage = $this->setArrayToStringForUrl('&amp;', $alR, ['lang']).'&amp;';
708 708
         }
709 709
         $sReturn = [];
710 710
         foreach ($aAvailableLanguages as $key => $value) {
711 711
             if ($this->tCmnSession->get('lang') !== $key) {
712
-                $sReturn[] = '<a href="?' . $linkWithoutLanguage . 'lang=' . $key . '" style="display:block;">'
713
-                    . '<span class="flag-icon flag-icon-' . strtolower(substr($key, -2))
714
-                    . '" style="margin-right:2px;">&nbsp;</span>' . $value . '</a>';
712
+                $sReturn[] = '<a href="?'.$linkWithoutLanguage.'lang='.$key.'" style="display:block;">'
713
+                    . '<span class="flag-icon flag-icon-'.strtolower(substr($key, -2))
714
+                    . '" style="margin-right:2px;">&nbsp;</span>'.$value.'</a>';
715 715
             }
716 716
         }
717
-        return '<div id="visibleOnHover">' . implode('', $sReturn) . '</div><!-- visibleOnHover end -->';
717
+        return '<div id="visibleOnHover">'.implode('', $sReturn).'</div><!-- visibleOnHover end -->';
718 718
     }
719 719
 
720 720
 }
Please login to merge, or discard this patch.
source/MySQLiByDanielGPnumbers.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
     protected function getFieldOutputEnumSetReadOnly($val, $adnlThings)
49 49
     {
50 50
         $inputFeatures = [
51
-            'name'     => $val['COLUMN_NAME'] . $adnlThings['suffix'],
51
+            'name'     => $val['COLUMN_NAME'].$adnlThings['suffix'],
52 52
             'id'       => $val['COLUMN_NAME'],
53 53
             'readonly' => 'readonly',
54 54
             'class'    => 'input_readonly',
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
      */
129 129
     protected function setFieldLabel($details, $features, $fieldLabel)
130 130
     {
131
-        $aLabel = ['for' => $details['COLUMN_NAME'], 'id' => $details['COLUMN_NAME'] . '_label'];
131
+        $aLabel = ['for' => $details['COLUMN_NAME'], 'id' => $details['COLUMN_NAME'].'_label'];
132 132
         if (isset($features['disabled'])) {
133 133
             if (in_array($details['COLUMN_NAME'], $features['disabled'])) {
134 134
                 $aLabel = array_merge($aLabel, ['style' => 'color: grey;']);
@@ -186,7 +186,7 @@  discard block
 block discarded – undo
186 186
 
187 187
     private function setFldLmtsExact($dTp, $cTp)
188 188
     {
189
-        $xct     = [
189
+        $xct = [
190 190
             'bigint'    => ['l' => -9223372036854775808, 'L' => 999999999999, 's' => 21, 'sUS' => 20],
191 191
             'int'       => ['l' => -2147483648, 'L' => 2147483647, 's' => 11, 'sUS' => 10],
192 192
             'mediumint' => ['l' => -8388608, 'L' => 8388607, 's' => 9, 'sUS' => 8],
@@ -214,16 +214,16 @@  discard block
 block discarded – undo
214 214
     {
215 215
         $btn   = [];
216 216
         $btn[] = '<input type="submit" id="submit" style="margin-left:220px;" value="'
217
-            . $this->lclMsgCmn('i18n_Form_ButtonSave') . '" />';
217
+            . $this->lclMsgCmn('i18n_Form_ButtonSave').'" />';
218 218
         if (isset($feat['insertAndUpdate'])) {
219 219
             $btn[] = '<input type="hidden" id="insertAndUpdate" name="insertAndUpdate" value="insertAndUpdate" />';
220 220
         }
221 221
         if ($hiddenInfo != []) {
222 222
             foreach ($hiddenInfo as $key => $value) {
223
-                $btn[] = '<input type="hidden" id="' . $key . '" name="' . $key . '" value="' . $value . '" />';
223
+                $btn[] = '<input type="hidden" id="'.$key.'" name="'.$key.'" value="'.$value.'" />';
224 224
             }
225 225
         }
226
-        return '<div>' . implode('', $btn) . '</div>';
226
+        return '<div>'.implode('', $btn).'</div>';
227 227
     }
228 228
 
229 229
     /**
@@ -238,7 +238,7 @@  discard block
 block discarded – undo
238 238
             $elC = [$prm['NoOfRows'], $rMap[$prm['returnType']]['r'][0], $rMap[$prm['returnType']]['r'][1]];
239 239
             if (filter_var($elC[0], FILTER_VALIDATE_INT, ['min_range' => $elC[1], 'max_range' => $elC[2]]) === false) {
240 240
                 $suffix2 = (string) $rMap[$prm['returnType']][2];
241
-                $msg     = $this->lclMsgCmn('i18n_MySQL_QueryResultExpected' . $suffix2);
241
+                $msg     = $this->lclMsgCmn('i18n_MySQL_QueryResultExpected'.$suffix2);
242 242
                 return [false, sprintf($msg, $prm['NoOfColumns'])];
243 243
             }
244 244
             $elR = [$prm['NoOfColumns'], $rMap[$prm['returnType']]['c'][0], $rMap[$prm['returnType']]['c'][1]];
@@ -246,10 +246,10 @@  discard block
 block discarded – undo
246 246
                 return [true, ''];
247 247
             }
248 248
             $suffix1 = (string) $rMap[$prm['returnType']][1];
249
-            $msg     = $this->lclMsgCmn('i18n_MySQL_QueryResultExpected' . $suffix1);
249
+            $msg     = $this->lclMsgCmn('i18n_MySQL_QueryResultExpected'.$suffix1);
250 250
             return [false, sprintf($msg, $prm['NoOfColumns'])];
251 251
         }
252
-        return [false, $prm['returnType'] . ' is not defined!'];
252
+        return [false, $prm['returnType'].' is not defined!'];
253 253
     }
254 254
 
255 255
     private function setMySQLqueryValidationMap()
Please login to merge, or discard this patch.
source/MySQLiByDanielGPtypes.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -68,11 +68,11 @@  discard block
 block discarded – undo
68 68
      */
69 69
     private function listOfMySQLqueryLanguageType($qType)
70 70
     {
71
-        $keyForReturn = 'Type ' . $qType . ' stands for';
71
+        $keyForReturn = 'Type '.$qType.' stands for';
72 72
         $vMap         = ['DCL', 'DDL', 'DML', 'DQL', 'DTL'];
73 73
         if (in_array($qType, $vMap)) {
74 74
             $valForReturn = $this->readTypeFromJsonFile('MySQLiLanguageTypes')[$qType];
75
-            return [$keyForReturn => $valForReturn[0] . ' (' . $valForReturn[1] . ')'];
75
+            return [$keyForReturn => $valForReturn[0].' ('.$valForReturn[1].')'];
76 76
         }
77 77
         return [$keyForReturn => 'unknown'];
78 78
     }
@@ -102,10 +102,10 @@  discard block
 block discarded – undo
102 102
      */
103 103
     private function readTypeFromJsonFile($fileBaseName)
104 104
     {
105
-        $fName = __DIR__ . DIRECTORY_SEPARATOR . 'json' . DIRECTORY_SEPARATOR . $fileBaseName . '.min.json';
105
+        $fName = __DIR__.DIRECTORY_SEPARATOR.'json'.DIRECTORY_SEPARATOR.$fileBaseName.'.min.json';
106 106
         $fJson = fopen($fName, 'r');
107 107
         if ($fJson === false) {
108
-            throw new \Exception('Unable to read file ' . $fName);
108
+            throw new \Exception('Unable to read file '.$fName);
109 109
         }
110 110
         $jSonContent = fread($fJson, filesize($fName));
111 111
         fclose($fJson);
Please login to merge, or discard this patch.
source/DomPaginationByDanielGP.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
                 'class'    => 'input_readonly',
86 86
                 'value'    => $sDefaultValue,
87 87
             ];
88
-            return $this->setStringIntoShortTag('input', $inputFeatures) . $aElements[$sDefaultValue];
88
+            return $this->setStringIntoShortTag('input', $inputFeatures).$aElements[$sDefaultValue];
89 89
         }
90 90
         return $this->setArrayToSelectNotReadOnly($aElements, $sDefaultValue, $selectName, $featArray);
91 91
     }
@@ -122,21 +122,21 @@  discard block
 block discarded – undo
122 122
         $sReturn             = null;
123 123
         $iRecPrPg            = min($inRecPrPg, $iAllRec);
124 124
         $iStartingPageRecord = $this->setStartingPageRecord($iCrtPgNo, $iRecPrPg, $iAllRec, $bKpFlPg);
125
-        $sReturn             .= '<span style="float:left;font-size:smaller;margin-top:1px; margin-right:1px;">'
125
+        $sReturn .= '<span style="float:left;font-size:smaller;margin-top:1px; margin-right:1px;">'
126 126
             . $this->setStringIntoTag($iAllRec, 'b')
127 127
             . $this->lclMsgCmn('i18n_RecordsAvailableNowDisplaying')
128 128
             . $this->setStringIntoTag(($iStartingPageRecord + 1), 'b')
129
-            . ' - ' . $this->setStringIntoTag(min($iAllRec, ($iStartingPageRecord + $iRecPrPg)), 'b')
129
+            . ' - '.$this->setStringIntoTag(min($iAllRec, ($iStartingPageRecord + $iRecPrPg)), 'b')
130 130
             . ' </span>';
131 131
         switch ($iCrtPgNo) {
132 132
             case 'first':
133
-                $iCrtPgNo = ceil(($iStartingPageRecord + 1 ) / $iRecPrPg);
133
+                $iCrtPgNo = ceil(($iStartingPageRecord + 1) / $iRecPrPg);
134 134
                 break;
135 135
             case 'last':
136 136
                 $iCrtPgNo = ceil($iAllRec / $iRecPrPg);
137 137
                 break;
138 138
         }
139
-        $sReturn              .= '<span style="float:right;font-size:smaller;margin-top:1px; margin-right:1px;">';
139
+        $sReturn .= '<span style="float:right;font-size:smaller;margin-top:1px; margin-right:1px;">';
140 140
         $iNumberOfPages       = ceil($iAllRec / $iRecPrPg);
141 141
         $sAdditionalArguments = '';
142 142
         if (isset($_GET)) {
@@ -150,7 +150,7 @@  discard block
 block discarded – undo
150 150
         }
151 151
         if ($iCrtPgNo != 1) {
152 152
             $sReturn .= $this->setStringIntoTag($this->lclMsgCmn('i18n_Previous'), 'a', [
153
-                'href'  => ('?page=' . ($iCrtPgNo - 1 ) . $sAdditionalArguments ),
153
+                'href'  => ('?page='.($iCrtPgNo - 1).$sAdditionalArguments),
154 154
                 'class' => 'pagination'
155 155
             ]);
156 156
         } else {
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
         for ($counter = 1; $counter <= $iNumberOfPages; $counter++) {
163 163
             $pages2display[$counter] = $counter;
164 164
         }
165
-        $sReturn .= '<span class="pagination"><form method="get" action="' . $_SERVER['SCRIPT_NAME'] . '">';
165
+        $sReturn .= '<span class="pagination"><form method="get" action="'.$_SERVER['SCRIPT_NAME'].'">';
166 166
         $sReturn .= $this->setArrayToSelect($pages2display, @$_REQUEST['page']
167 167
             , 'page', ['size' => 1, 'autosubmit', 'id_no' => mt_rand()]);
168 168
         if (isset($_GET)) {
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
                         foreach ($value as $value2) {
173 173
                             $sReturn .= $this->setStringIntoShortTag('input', [
174 174
                                 'type'  => 'hidden',
175
-                                'name'  => $key . '[]',
175
+                                'name'  => $key.'[]',
176 176
                                 'value' => $value2,
177 177
                             ]);
178 178
                         }
@@ -189,7 +189,7 @@  discard block
 block discarded – undo
189 189
         $sReturn .= '</form></span>';
190 190
         if ($iCrtPgNo != $iNumberOfPages) {
191 191
             $sReturn .= $this->setStringIntoTag($this->lclMsgCmn('i18n_Next'), 'a', [
192
-                'href'  => ('?page=' . ($iCrtPgNo + 1 ) . $sAdditionalArguments ),
192
+                'href'  => ('?page='.($iCrtPgNo + 1).$sAdditionalArguments),
193 193
                 'class' => 'pagination',
194 194
             ]);
195 195
         } else {
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
         , $iAllRecords, $bKeepFullPage = true)
216 216
     {
217 217
         if (isset($_REQUEST['page'])) {
218
-            $iStartingPageRecord = ($_REQUEST['page'] - 1 ) * $iRecordsPerPage;
218
+            $iStartingPageRecord = ($_REQUEST['page'] - 1) * $iRecordsPerPage;
219 219
         } else {
220 220
             switch ($sDefaultPageNo) {
221 221
                 case 'last':
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
                     break;
228 228
             }
229 229
         }
230
-        if (($bKeepFullPage ) && (($iStartingPageRecord + $iRecordsPerPage ) > $iAllRecords)) {
230
+        if (($bKeepFullPage) && (($iStartingPageRecord + $iRecordsPerPage) > $iAllRecords)) {
231 231
             $iStartingPageRecord = $iAllRecords - $iRecordsPerPage;
232 232
         }
233 233
         return max(0, $iStartingPageRecord);
Please login to merge, or discard this patch.
source/DomDynamicSelectByDanielGP.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
             $sReturn[] = 'submit();';
100 100
         }
101 101
         if ($sReturn != []) {
102
-            return ' onchange="javascript:' . implode('', $sReturn) . '"';
102
+            return ' onchange="javascript:'.implode('', $sReturn).'"';
103 103
         }
104 104
         return '';
105 105
     }
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
         ];
117 117
         if (array_key_exists($identifier, $featArray)) {
118 118
             if (is_null($translation[$identifier])) {
119
-                return ' ' . $identifier . '="' . $featArray[$identifier] . '"';
119
+                return ' '.$identifier.'="'.$featArray[$identifier].'"';
120 120
             }
121 121
             return $translation[$identifier];
122 122
         }
@@ -141,15 +141,15 @@  discard block
 block discarded – undo
141 141
             $ftArray = [];
142 142
         }
143 143
         $featArray = $this->normalizeFeatureArray($ftArray);
144
-        return '<select name="' . $selectName . '" '
145
-            . 'id="' . $this->buildSelectId($selectName, $featArray) . '" '
146
-            . 'size="' . $this->calculateSelectOptionsSize($aElements, $featArray) . '"'
144
+        return '<select name="'.$selectName.'" '
145
+            . 'id="'.$this->buildSelectId($selectName, $featArray).'" '
146
+            . 'size="'.$this->calculateSelectOptionsSize($aElements, $featArray).'"'
147 147
             . $this->eventOnChange($featArray)
148 148
             . $this->featureArraySimpleTranslated($featArray, 'disabled')
149 149
             . $this->featureArraySimpleTranslated($featArray, 'hidden')
150 150
             . $this->featureArraySimpleTranslated($featArray, 'multiselect')
151 151
             . $this->featureArraySimpleTranslated($featArray, 'style')
152
-            . '>' . $this->setOptionsForSelect($aElements, $sDefaultValue, $featArray) . '</select>';
152
+            . '>'.$this->setOptionsForSelect($aElements, $sDefaultValue, $featArray).'</select>';
153 153
     }
154 154
 
155 155
     private function setOptionGroupEnd($crtGroup, $featArray)
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
             if ($crtGroup != $tempString) {
171 171
                 $sReturn[] = $this->setOptionGroupEnd($crtGroup, $featArray);
172 172
                 $crtGroup  = $tempString;
173
-                $sReturn[] = '<optgroup label="' . str_replace($featArray['grouping'], '', $crtGroup) . '">';
173
+                $sReturn[] = '<optgroup label="'.str_replace($featArray['grouping'], '', $crtGroup).'">';
174 174
             }
175 175
         }
176 176
         return ['crtGroup' => $crtGroup, 'groupFooterHeader' => implode('', $sReturn)];
@@ -207,12 +207,12 @@  discard block
 block discarded – undo
207 207
             $aFH       = $this->setOptionGroupFooterHeader($featArray, $value, $crtGroup);
208 208
             $crtGroup  = $aFH['crtGroup'];
209 209
             $sReturn[] = $aFH['groupFooterHeader']
210
-                . '<option value="' . $key . '"' . $this->setOptionSelected($key, $sDefaultValue)
211
-                . $this->featureArraySimpleTranslated($featArray, 'styleForOption') . '>'
212
-                . str_replace(['&', $crtGroup], ['&amp;', ''], $value) . '</option>';
210
+                . '<option value="'.$key.'"'.$this->setOptionSelected($key, $sDefaultValue)
211
+                . $this->featureArraySimpleTranslated($featArray, 'styleForOption').'>'
212
+                . str_replace(['&', $crtGroup], ['&amp;', ''], $value).'</option>';
213 213
         }
214 214
         $sReturn[] = $this->setOptionGroupEnd($crtGroup, $featArray);
215
-        return $this->featureArraySimpleTranslated($featArray, 'include_null') . implode('', $sReturn);
215
+        return $this->featureArraySimpleTranslated($featArray, 'include_null').implode('', $sReturn);
216 216
     }
217 217
 
218 218
 }
Please login to merge, or discard this patch.
source/MySQLiAdvancedOutput.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
         }
60 60
         $vlSlct    = explode(',', $this->getFieldValue($val));
61 61
         $slctOptns = $this->getSetOrEnum2Array($tblSrc, $val['COLUMN_NAME']);
62
-        return $this->setArrayToSelect($slctOptns, $vlSlct, $val['COLUMN_NAME'] . $adnlThings['suffix'], $inAdtnl);
62
+        return $this->setArrayToSelect($slctOptns, $vlSlct, $val['COLUMN_NAME'].$adnlThings['suffix'], $inAdtnl);
63 63
     }
64 64
 
65 65
     /**
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
         if ($iar !== []) {
106 106
             $inAdtnl = array_merge($inAdtnl, $iar);
107 107
         }
108
-        return '<b>' . $this->getFieldValue($value) . '</b>' . $this->setStringIntoShortTag('input', $inAdtnl);
108
+        return '<b>'.$this->getFieldValue($value).'</b>'.$this->setStringIntoShortTag('input', $inAdtnl);
109 109
     }
110 110
 
111 111
     /**
@@ -118,8 +118,8 @@  discard block
 block discarded – undo
118 118
      */
119 119
     private function getFieldOutputNumericNonFK($fkArray, $value, $iar = [])
120 120
     {
121
-        $query         = $this->sQueryGenericSelectKeyValue([
122
-            '`' . $value['COLUMN_NAME'] . '`',
121
+        $query = $this->sQueryGenericSelectKeyValue([
122
+            '`'.$value['COLUMN_NAME'].'`',
123 123
             $fkArray[$value['COLUMN_NAME']][2],
124 124
             $fkArray[$value['COLUMN_NAME']][0],
125 125
         ]);
@@ -260,7 +260,7 @@  discard block
 block discarded – undo
260 260
                 if ($val[$cnm[0]] == $oCol) {
261 261
                     $vlQ        = array_merge($val, ['LIMIT' => 2]);
262 262
                     $tFd        = $this->setMySQLquery2Server($this->getForeignKeysQuery($vlQ), $cnm[1])['result'];
263
-                    $tgtFld     = '`' . ($tFd[0][$cnm[0]] == $val[$cnm[0]] ? $tFd[1][$cnm[0]] : $tFd[0][$cnm[0]]) . '`';
263
+                    $tgtFld     = '`'.($tFd[0][$cnm[0]] == $val[$cnm[0]] ? $tFd[1][$cnm[0]] : $tFd[0][$cnm[0]]).'`';
264 264
                     $aRt[$oCol] = [$this->glueDbTb($val[$cnm[2]], $val[$cnm[3]]), $val[$cnm[2]], $tgtFld];
265 265
                 }
266 266
             }
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
                 $inM = $this->setStringIntoTag($mCN[$dtl['COLUMN_NAME']], 'span', ['style' => 'font-style:italic;']);
312 312
             }
313 313
         }
314
-        $lbl = '<span class="fake_label">' . $this->getFieldNameForDisplay($dtl) . '</span>';
314
+        $lbl = '<span class="fake_label">'.$this->getFieldNameForDisplay($dtl).'</span>';
315 315
         return ['label' => $lbl, 'input' => $inM];
316 316
     }
317 317
 
@@ -327,7 +327,7 @@  discard block
 block discarded – undo
327 327
         } elseif (in_array($dtls['DATA_TYPE'], ['date', 'datetime', 'time', 'timestamp', 'year'])) {
328 328
             $sReturn = $this->setNeededFieldSingleType($tblName, $dtls, $iar);
329 329
         }
330
-        return $this->getFieldCompletionType($dtls) . $sReturn;
330
+        return $this->getFieldCompletionType($dtls).$sReturn;
331 331
     }
332 332
 
333 333
     private function setNeededFieldSingleType($tblName, $dtls, $iar)
Please login to merge, or discard this patch.
source/MySQLiByDanielGPqueries.php 1 patch
Spacing   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
     private function correctTableWithQuotesAsFieldPrefix($referenceTable)
49 49
     {
50 50
         if ($referenceTable != '') {
51
-            return '`' . str_replace('`', '', $referenceTable) . '`.';
51
+            return '`'.str_replace('`', '', $referenceTable).'`.';
52 52
         }
53 53
         return '';
54 54
     }
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
     private function sGlueFilterValIntoWhereStr($filterValue)
82 82
     {
83 83
         if (is_array($filterValue)) {
84
-            return 'IN ("' . implode('", "', $filterValue) . '")';
84
+            return 'IN ("'.implode('", "', $filterValue).'")';
85 85
         }
86 86
         return $this->sGlueFilterValueIntoWhereStringFinal($filterValue);
87 87
     }
@@ -94,13 +94,13 @@  discard block
 block discarded – undo
94 94
             'NOT NULL|NULL',
95 95
         ];
96 96
         if (in_array($filterValue, explode('|', $kFields[0]))) {
97
-            return '= ' . $filterValue;
97
+            return '= '.$filterValue;
98 98
         } elseif (in_array($filterValue, explode('|', $kFields[1]))) {
99 99
             return $filterValue;
100 100
         } elseif (in_array($filterValue, explode('|', $kFields[2]))) {
101
-            return 'IS ' . $filterValue;
101
+            return 'IS '.$filterValue;
102 102
         }
103
-        return '= "' . $filterValue . '"';
103
+        return '= "'.$filterValue.'"';
104 104
     }
105 105
 
106 106
     /**
@@ -111,7 +111,7 @@  discard block
 block discarded – undo
111 111
      */
112 112
     private function sGlueFiltersIntoWhereArrayFilter($filters)
113 113
     {
114
-        return '(' . implode(') AND (', $filters) . ')';
114
+        return '('.implode(') AND (', $filters).')';
115 115
     }
116 116
 
117 117
     /**
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
         $fltr = [];
130 130
         unset($filterArray['LIMIT']);
131 131
         foreach ($filterArray as $key => $value) {
132
-            $fltr[] = '`' . $tableToApplyFilterTo . '`.`' . $key . '` ' . $this->sGlueFilterValIntoWhereStr($value);
132
+            $fltr[] = '`'.$tableToApplyFilterTo.'`.`'.$key.'` '.$this->sGlueFilterValIntoWhereStr($value);
133 133
         }
134 134
         return $this->sManageDynamicFiltersFinal($fltr);
135 135
     }
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
     {
139 139
         if (count($filters) > 0) {
140 140
             $sReturn = ['WHERE', $this->sGlueFiltersIntoWhereArrayFilter($filters)];
141
-            return implode(' ', $sReturn) . ' ';
141
+            return implode(' ', $sReturn).' ';
142 142
         }
143 143
         return '';
144 144
     }
@@ -159,13 +159,13 @@  discard block
 block discarded – undo
159 159
         $filterArray = (is_array($filterArray) ? $filterArray : ['' => '']);
160 160
         return 'SELECT '
161 161
             . '`C`.`TABLE_SCHEMA`, '
162
-            . $this->sQueryMySqlColumnsColumns() . ' '
162
+            . $this->sQueryMySqlColumnsColumns().' '
163 163
             . 'FROM `information_schema`.`COLUMNS` `C` '
164
-            . 'LEFT JOIN `information_schema`.`KEY_COLUMN_USAGE` `KCU` ON ((' . implode(') AND (', [
164
+            . 'LEFT JOIN `information_schema`.`KEY_COLUMN_USAGE` `KCU` ON (('.implode(') AND (', [
165 165
                 '`C`.`TABLE_SCHEMA` = `KCU`.`TABLE_SCHEMA`',
166 166
                 '`C`.`TABLE_NAME` = `KCU`.`TABLE_NAME`',
167 167
                 '`C`.`COLUMN_NAME` = `KCU`.`COLUMN_NAME`',
168
-            ]) . ')) '
168
+            ]).')) '
169 169
             . $this->sManageDynamicFilters($filterArray, 'C')
170 170
             . 'GROUP BY `C`.`TABLE_SCHEMA`, `C`.`TABLE_NAME`, `C`.`COLUMN_NAME` '
171 171
             . 'ORDER BY `C`.`TABLE_SCHEMA`, `C`.`TABLE_NAME`, `C`.`ORDINAL_POSITION` '
@@ -192,20 +192,20 @@  discard block
 block discarded – undo
192 192
     {
193 193
         return 'SELECT '
194 194
             . '`KCU`.`CONSTRAINT_SCHEMA`, '
195
-            . $this->sQueryMySqlIndexesColumns() . ' '
195
+            . $this->sQueryMySqlIndexesColumns().' '
196 196
             . 'FROM `information_schema`.`KEY_COLUMN_USAGE` `KCU` '
197
-            . 'INNER JOIN `information_schema`.`COLUMNS` `C` ON ((' . implode(') AND (', [
197
+            . 'INNER JOIN `information_schema`.`COLUMNS` `C` ON (('.implode(') AND (', [
198 198
                 '`C`.`TABLE_SCHEMA` = `KCU`.`TABLE_SCHEMA`',
199 199
                 '`C`.`TABLE_NAME` = `KCU`.`TABLE_NAME`',
200 200
                 '`C`.`COLUMN_NAME` = `KCU`.`COLUMN_NAME`',
201
-            ]) . ')) '
202
-            . 'LEFT JOIN `information_schema`.`REFERENTIAL_CONSTRAINTS` `RC` ON ((' . implode(') AND (', [
201
+            ]).')) '
202
+            . 'LEFT JOIN `information_schema`.`REFERENTIAL_CONSTRAINTS` `RC` ON (('.implode(') AND (', [
203 203
                 '`KCU`.`CONSTRAINT_SCHEMA` = `RC`.`CONSTRAINT_SCHEMA`',
204 204
                 '`KCU`.`CONSTRAINT_NAME` = `RC`.`CONSTRAINT_NAME`',
205
-            ]) . ')) '
205
+            ]).')) '
206 206
             . $this->sManageDynamicFilters($filterArray, 'KCU')
207 207
             . 'ORDER BY `KCU`.`TABLE_SCHEMA`, `KCU`.`TABLE_NAME`'
208
-            . $this->xtraSoring($filterArray, 'COLUMN_NAME') . ';';
208
+            . $this->xtraSoring($filterArray, 'COLUMN_NAME').';';
209 209
     }
210 210
 
211 211
     private function sQueryMySqlIndexesColumns()
@@ -221,23 +221,23 @@  discard block
 block discarded – undo
221 221
     {
222 222
         $tblAls  = substr($tblName, 0, 1);
223 223
         $colName = (is_null($adtnlCol) ? $tblName : $adtnlFltr);
224
-        return '(SELECT COUNT(*) AS `No. of records` FROM `information_schema`.`' . $tblName . '` `' . $tblAls . '` '
225
-            . 'WHERE (`' . $tblAls . '`.`' . $lnkDbCol . '` = `S`.`SCHEMA_NAME`)'
226
-            . (!is_null($adtnlCol) ? ' AND (`' . $tblAls . '`.`' . $adtnlCol . '` = "' . $adtnlFltr . '")' : '')
227
-            . ') AS `' . ucwords(strtolower($colName)) . '`';
224
+        return '(SELECT COUNT(*) AS `No. of records` FROM `information_schema`.`'.$tblName.'` `'.$tblAls.'` '
225
+            . 'WHERE (`'.$tblAls.'`.`'.$lnkDbCol.'` = `S`.`SCHEMA_NAME`)'
226
+            . (!is_null($adtnlCol) ? ' AND (`'.$tblAls.'`.`'.$adtnlCol.'` = "'.$adtnlFltr.'")' : '')
227
+            . ') AS `'.ucwords(strtolower($colName)).'`';
228 228
     }
229 229
 
230 230
     protected function sQueryMySqlStatistics($filterArray = null)
231 231
     {
232 232
         return 'SELECT '
233 233
             . '`S`.`SCHEMA_NAME`, '
234
-            . $this->sQueryMySqlStatisticPattern('TABLES', 'TABLE_SCHEMA', 'TABLE_TYPE', 'BASE TABLE') . ', '
235
-            . $this->sQueryMySqlStatisticPattern('TABLES', 'TABLE_SCHEMA', 'TABLE_TYPE', 'VIEW') . ', '
236
-            . $this->sQueryMySqlStatisticPattern('COLUMNS', 'TABLE_SCHEMA') . ', '
237
-            . $this->sQueryMySqlStatisticPattern('TRIGGERS', 'EVENT_OBJECT_SCHEMA') . ', '
238
-            . $this->sQueryMySqlStatisticPattern('ROUTINES', 'ROUTINE_SCHEMA', 'ROUTINE_TYPE', 'Function') . ', '
239
-            . $this->sQueryMySqlStatisticPattern('ROUTINES', 'ROUTINE_SCHEMA', 'ROUTINE_TYPE', 'Procedure') . ', '
240
-            . $this->sQueryMySqlStatisticPattern('EVENTS', 'EVENT_SCHEMA') . ' '
234
+            . $this->sQueryMySqlStatisticPattern('TABLES', 'TABLE_SCHEMA', 'TABLE_TYPE', 'BASE TABLE').', '
235
+            . $this->sQueryMySqlStatisticPattern('TABLES', 'TABLE_SCHEMA', 'TABLE_TYPE', 'VIEW').', '
236
+            . $this->sQueryMySqlStatisticPattern('COLUMNS', 'TABLE_SCHEMA').', '
237
+            . $this->sQueryMySqlStatisticPattern('TRIGGERS', 'EVENT_OBJECT_SCHEMA').', '
238
+            . $this->sQueryMySqlStatisticPattern('ROUTINES', 'ROUTINE_SCHEMA', 'ROUTINE_TYPE', 'Function').', '
239
+            . $this->sQueryMySqlStatisticPattern('ROUTINES', 'ROUTINE_SCHEMA', 'ROUTINE_TYPE', 'Procedure').', '
240
+            . $this->sQueryMySqlStatisticPattern('EVENTS', 'EVENT_SCHEMA').' '
241 241
             . 'FROM `information_schema`.`SCHEMATA` `S` '
242 242
             . 'WHERE (`S`.`SCHEMA_NAME` NOT IN ("information_schema", "mysql", "performance_schema", "sys")) '
243 243
             . str_replace('WHERE', 'AND', $this->sManageDynamicFilters($filterArray, 'S'))
@@ -258,7 +258,7 @@  discard block
 block discarded – undo
258 258
             . ', `T`.`CREATE_OPTIONS`, `T`.`TABLE_COMMENT` '
259 259
             . 'FROM `information_schema`.`TABLES` `T` '
260 260
             . $this->sManageDynamicFilters($filterArray, 'T')
261
-            . $this->xtraSoring($filterArray, 'TABLE_SCHEMA') . ';';
261
+            . $this->xtraSoring($filterArray, 'TABLE_SCHEMA').';';
262 262
     }
263 263
 
264 264
     /**
@@ -273,8 +273,8 @@  discard block
 block discarded – undo
273 273
     {
274 274
         $filters2 = implode(', ', array_diff($value, ['']));
275 275
         if ($filters2 != '') {
276
-            return '(' . $referenceTable . '`' . $key . '` IN ("'
277
-                . str_replace(',', '","', str_replace(["'", '"'], '', $filters2)) . '"))';
276
+            return '('.$referenceTable.'`'.$key.'` IN ("'
277
+                . str_replace(',', '","', str_replace(["'", '"'], '', $filters2)).'"))';
278 278
         }
279 279
         return '';
280 280
     }
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
         if ((substr($value, 0, 1) == '%') && (substr($value, -1) == '%')) {
293 293
             $fTemp = 'LIKE';
294 294
         }
295
-        return '(`' . $key . '` ' . $fTemp . '"' . $value . '")';
295
+        return '(`'.$key.'` '.$fTemp.'"'.$value.'")';
296 296
     }
297 297
 
298 298
     private function xtraSoring($filterArray, $filterValueToDecide)
Please login to merge, or discard this patch.
source/MySQLiByDanielGPstructures.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
      */
67 67
     protected function getFieldNameForDisplay($details)
68 68
     {
69
-        $tableUniqueId = $details['TABLE_SCHEMA'] . '.' . $details['TABLE_NAME'];
69
+        $tableUniqueId = $details['TABLE_SCHEMA'].'.'.$details['TABLE_NAME'];
70 70
         if ($details['COLUMN_COMMENT'] != '') {
71 71
             return $details['COLUMN_COMMENT'];
72 72
         } elseif (isset($this->advCache['tableStructureLocales'][$tableUniqueId][$details['COLUMN_NAME']])) {
@@ -85,8 +85,8 @@  discard block
 block discarded – undo
85 85
      */
86 86
     protected function getFieldOutputTextFK($foreignKeysArray, $value, $iar)
87 87
     {
88
-        $query   = $this->sQueryGenericSelectKeyValue([
89
-            '`' . $value['COLUMN_NAME'] . '`',
88
+        $query = $this->sQueryGenericSelectKeyValue([
89
+            '`'.$value['COLUMN_NAME'].'`',
90 90
             $foreignKeysArray[$value['COLUMN_NAME']][2],
91 91
             $foreignKeysArray[$value['COLUMN_NAME']][0]
92 92
         ]);
Please login to merge, or discard this patch.