Completed
Push — master ( 710241...4d2382 )
by Daniel
02:32
created
source/OutputFormBuilder.php 1 patch
Spacing   +22 added lines, -22 removed lines patch added patch discarded remove patch
@@ -31,12 +31,12 @@  discard block
 block discarded – undo
31 31
 
32 32
     private function listOfKnownLabels($inArray)
33 33
     {
34
-        $informatorKnownLabels = array_diff($inArray['KnownLabels'], ['--- List of known labels']);
35
-        $tmpOptions            = [];
34
+        $informatorKnownLabels = array_diff($inArray[ 'KnownLabels' ], [ '--- List of known labels' ]);
35
+        $tmpOptions            = [ ];
36 36
         foreach ($informatorKnownLabels as $value) {
37
-            $tmpOptions[] = '<input type="radio" name="Label" id="Label_' . $value . '" value="' . $value . '" '
37
+            $tmpOptions[ ] = '<input type="radio" name="Label" id="Label_' . $value . '" value="' . $value . '" '
38 38
                     . $this->turnRequestedValueIntoCheckboxStatus([
39
-                        'SuperGlobals'  => $inArray['SuperGlobals'],
39
+                        'SuperGlobals'  => $inArray[ 'SuperGlobals' ],
40 40
                         'RequestedName' => 'Label',
41 41
                         'CheckedValue'  => $value,
42 42
                     ])
@@ -51,44 +51,44 @@  discard block
 block discarded – undo
51 51
 
52 52
     private function providers($inArray)
53 53
     {
54
-        $tmpOptions = [];
55
-        foreach ($this->config['Servers'] as $key => $value) {
56
-            $tmpOptions[] = '<a href="' . $value['url'] . '" target="_blank">run-me</a>&nbsp;'
57
-                    . '<input type="radio" name="' . $inArray['ConfigName'] . '" id="'
58
-                    . $inArray['ConfigName'] . '_' . $key . '" value="' . $key . '" '
54
+        $tmpOptions = [ ];
55
+        foreach ($this->config[ 'Servers' ] as $key => $value) {
56
+            $tmpOptions[ ] = '<a href="' . $value[ 'url' ] . '" target="_blank">run-me</a>&nbsp;'
57
+                    . '<input type="radio" name="' . $inArray[ 'ConfigName' ] . '" id="'
58
+                    . $inArray[ 'ConfigName' ] . '_' . $key . '" value="' . $key . '" '
59 59
                     . $this->turnRequestedValueIntoCheckboxStatus([
60
-                        'SuperGlobals'  => $inArray['SuperGlobals'],
61
-                        'RequestedName' => $inArray['ConfigName'],
60
+                        'SuperGlobals'  => $inArray[ 'SuperGlobals' ],
61
+                        'RequestedName' => $inArray[ 'ConfigName' ],
62 62
                         'CheckedValue'  => (string) $key,
63 63
                     ])
64 64
                     . '/>'
65
-                    . '<label for="' . $inArray['ConfigName'] . '_' . $key . '">' . $value['name'] . '</label>';
65
+                    . '<label for="' . $inArray[ 'ConfigName' ] . '_' . $key . '">' . $value[ 'name' ] . '</label>';
66 66
         }
67 67
         return '<fieldset style="float:left;">'
68
-                . '<legend>' . $inArray['TitleStart'] . ' config providers</legend>'
68
+                . '<legend>' . $inArray[ 'TitleStart' ] . ' config providers</legend>'
69 69
                 . implode('<br/>', $tmpOptions)
70 70
                 . '</fieldset>';
71 71
     }
72 72
 
73 73
     protected function setFormOptions($inArray)
74 74
     {
75
-        $sReturn   = [];
76
-        $sReturn[] = $this->typeOfResults($inArray['SuperGlobals']);
77
-        $sReturn[] = $this->providers([
78
-            'SuperGlobals' => $inArray['SuperGlobals'],
75
+        $sReturn   = [ ];
76
+        $sReturn[ ] = $this->typeOfResults($inArray[ 'SuperGlobals' ]);
77
+        $sReturn[ ] = $this->providers([
78
+            'SuperGlobals' => $inArray[ 'SuperGlobals' ],
79 79
             'TitleStart'   => 'Source',
80 80
             'ConfigName'   => 'localConfig',
81 81
         ]);
82
-        $sReturn[] = $this->providers([
83
-            'SuperGlobals' => $inArray['SuperGlobals'],
82
+        $sReturn[ ] = $this->providers([
83
+            'SuperGlobals' => $inArray[ 'SuperGlobals' ],
84 84
             'TitleStart'   => 'Target',
85 85
             'ConfigName'   => 'serverConfig',
86 86
         ]);
87
-        $sReturn[] = $this->listOfKnownLabels($inArray);
87
+        $sReturn[ ] = $this->listOfKnownLabels($inArray);
88 88
         return '<div class="tabbertab" id="tabOptions" title="Options">'
89 89
                 . '<style type="text/css" media="all" scoped>label { width: auto; }</style>'
90 90
                 . '<form method="get" action="'
91
-                . $_SERVER['PHP_SELF'] . '">'
91
+                . $_SERVER[ 'PHP_SELF' ] . '">'
92 92
                 . '<input type="submit" value="Apply" />'
93 93
                 . '<br/>' . implode('', $sReturn)
94 94
                 . '</form>'
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
     private function turnRequestedValueIntoCheckboxStatus($inArray)
100 100
     {
101 101
         $checkboxStatus = '';
102
-        if ($inArray['SuperGlobals']->get($inArray['RequestedName']) === $inArray['CheckedValue']) {
102
+        if ($inArray[ 'SuperGlobals' ]->get($inArray[ 'RequestedName' ]) === $inArray[ 'CheckedValue' ]) {
103 103
             $checkboxStatus = 'checked ';
104 104
         }
105 105
         return $checkboxStatus;
Please login to merge, or discard this patch.