Passed
Push — master ( cb29e2...bc2fc1 )
by Daniel
02:47
created
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="' . $this->tCmnSuperGlobals->getScriptName() . '">';
165
+        $sReturn .= '<span class="pagination"><form method="get" action="'.$this->tCmnSuperGlobals->getScriptName().'">';
166 166
         $sReturn .= $this->setArrayToSelect($pages2display, $this->tCmnSuperGlobals->get('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 {
@@ -225,9 +225,9 @@  discard block
 block discarded – undo
225 225
                     break;
226 226
             }
227 227
         } else {
228
-            $iStartingPageRecord = ($this->tCmnSuperGlobals->get('page') - 1 ) * $iRecordsPerPage;
228
+            $iStartingPageRecord = ($this->tCmnSuperGlobals->get('page') - 1) * $iRecordsPerPage;
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.