Completed
Push — 1.10.x ( 23ca11...187186 )
by Julito
106:28 queued 51:04
created
main/inc/lib/pear/HTML/Table/Storage.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -128,8 +128,8 @@  discard block
 block discarded – undo
128 128
      */
129 129
     function HTML_Table_Storage($tabOffset = 0, $useTGroups = false)
130 130
     {
131
-        parent::__construct(null, (int)$tabOffset);
132
-        $this->_useTGroups = (boolean)$useTGroups;
131
+        parent::__construct(null, (int) $tabOffset);
132
+        $this->_useTGroups = (boolean) $useTGroups;
133 133
     }
134 134
 
135 135
     /**
@@ -288,7 +288,7 @@  discard block
 block discarded – undo
288 288
      */
289 289
     function setCellAttributes($row, $col, $attributes)
290 290
     {
291
-        if (   isset($this->_structure[$row][$col])
291
+        if (isset($this->_structure[$row][$col])
292 292
             && $this->_structure[$row][$col] == '__SPANNED__'
293 293
         ) {
294 294
             return;
@@ -314,7 +314,7 @@  discard block
 block discarded – undo
314 314
      */
315 315
     function updateCellAttributes($row, $col, $attributes)
316 316
     {
317
-        if (   isset($this->_structure[$row][$col])
317
+        if (isset($this->_structure[$row][$col])
318 318
             && $this->_structure[$row][$col] == '__SPANNED__'
319 319
         ) {
320 320
             return;
@@ -337,13 +337,13 @@  discard block
 block discarded – undo
337 337
      */
338 338
     function getCellAttributes($row, $col)
339 339
     {
340
-        if (   isset($this->_structure[$row][$col])
340
+        if (isset($this->_structure[$row][$col])
341 341
             && $this->_structure[$row][$col] != '__SPANNED__'
342 342
         ) {
343 343
             return $this->_structure[$row][$col]['attr'];
344 344
         } elseif (!isset($this->_structure[$row][$col])) {
345
-            return PEAR::raiseError('Invalid table cell reference[' .
346
-                $row . '][' . $col . '] in HTML_Table::getCellAttributes');
345
+            return PEAR::raiseError('Invalid table cell reference['.
346
+                $row.']['.$col.'] in HTML_Table::getCellAttributes');
347 347
         }
348 348
         return;
349 349
     }
@@ -405,7 +405,7 @@  discard block
 block discarded – undo
405 405
      */
406 406
     function _setSingleCellContents($row, $col, $contents, $type = 'TD')
407 407
     {
408
-        if (   isset($this->_structure[$row][$col])
408
+        if (isset($this->_structure[$row][$col])
409 409
             && $this->_structure[$row][$col] == '__SPANNED__'
410 410
         ) {
411 411
             return;
@@ -427,14 +427,14 @@  discard block
 block discarded – undo
427 427
      */
428 428
     function getCellContents($row, $col)
429 429
     {
430
-        if (   isset($this->_structure[$row][$col])
430
+        if (isset($this->_structure[$row][$col])
431 431
             && $this->_structure[$row][$col] == '__SPANNED__'
432 432
         ) {
433 433
             return;
434 434
         }
435 435
         if (!isset($this->_structure[$row][$col])) {
436
-            return PEAR::raiseError('Invalid table cell reference[' .
437
-                $row . '][' . $col . '] in HTML_Table::getCellContents');
436
+            return PEAR::raiseError('Invalid table cell reference['.
437
+                $row.']['.$col.'] in HTML_Table::getCellContents');
438 438
         }
439 439
         return $this->_structure[$row][$col]['contents'];
440 440
     }
@@ -477,7 +477,7 @@  discard block
 block discarded – undo
477 477
         $inTR = false)
478 478
     {
479 479
         if (isset($contents) && !is_array($contents)) {
480
-            return PEAR::raiseError('First parameter to HTML_Table::addRow ' .
480
+            return PEAR::raiseError('First parameter to HTML_Table::addRow '.
481 481
                 'must be an array');
482 482
         }
483 483
         if (is_null($contents)) {
@@ -620,7 +620,7 @@  discard block
 block discarded – undo
620 620
     function addCol($contents = null, $attributes = null, $type = 'td')
621 621
     {
622 622
         if (isset($contents) && !is_array($contents)) {
623
-            return PEAR::raiseError('First parameter to HTML_Table::addCol ' .
623
+            return PEAR::raiseError('First parameter to HTML_Table::addCol '.
624 624
                 'must be an array');
625 625
         }
626 626
         if (is_null($contents)) {
@@ -727,13 +727,13 @@  discard block
 block discarded – undo
727 727
             $extraTab = '';
728 728
         }
729 729
         if ($this->_cols > 0) {
730
-            for ($i = 0 ; $i < $this->_rows ; $i++) {
730
+            for ($i = 0; $i < $this->_rows; $i++) {
731 731
                 $attr = '';
732 732
                 if (isset($this->_structure[$i]['attr'])) {
733 733
                     $attr = $this->_getAttrString($this->_structure[$i]['attr']);
734 734
                 }
735
-                $strHtml .= $tabs .$tab . $extraTab . '<tr'.$attr.'>' . $lnEnd;
736
-                for ($j = 0 ; $j < $this->_cols ; $j++) {
735
+                $strHtml .= $tabs.$tab.$extraTab.'<tr'.$attr.'>'.$lnEnd;
736
+                for ($j = 0; $j < $this->_cols; $j++) {
737 737
                     $attr     = '';
738 738
                     $contents = '';
739 739
                     $type     = 'td';
@@ -753,7 +753,7 @@  discard block
 block discarded – undo
753 753
                     if (is_object($contents)) {
754 754
                         // changes indent and line end settings on nested tables
755 755
                         if (is_subclass_of($contents, 'html_common')) {
756
-                            $contents->setTab($tab . $extraTab);
756
+                            $contents->setTab($tab.$extraTab);
757 757
                             $contents->setTabOffset($this->_tabOffset + 3);
758 758
                             $contents->_nestLevel = $this->_nestLevel + 1;
759 759
                             $contents->setLineEnd($this->_getLineEnd());
@@ -768,7 +768,7 @@  discard block
 block discarded – undo
768 768
                         $contents = implode(', ', $contents);
769 769
                     }
770 770
 
771
-                    $typeContent = $tabs . $tab . $tab . $extraTab . "<$type" . $this->_getAttrString($attr) . '>';
771
+                    $typeContent = $tabs.$tab.$tab.$extraTab."<$type".$this->_getAttrString($attr).'>';
772 772
 
773 773
                     if (empty($contents)) {
774 774
                         if (isset($this->_autoFill) && $this->_autoFill) {
@@ -777,14 +777,14 @@  discard block
 block discarded – undo
777 777
                     } else {
778 778
                         $typeContent .= $contents;
779 779
                     }
780
-                    $typeContent .= "</$type>" . $lnEnd;
780
+                    $typeContent .= "</$type>".$lnEnd;
781 781
 
782 782
                     if (!empty($contents)) {
783 783
                         $strHtml .= $typeContent;
784 784
                     }
785 785
 
786 786
                 }
787
-                $strHtml .= $tabs . $tab . $extraTab . '</tr>' . $lnEnd;
787
+                $strHtml .= $tabs.$tab.$extraTab.'</tr>'.$lnEnd;
788 788
             }
789 789
         }
790 790
         return $strHtml;
Please login to merge, or discard this patch.
main/inc/lib/pear/OLE/PPS/Root.php 1 patch
Spacing   +43 added lines, -43 removed lines patch added patch discarded remove patch
@@ -89,14 +89,14 @@  discard block
 block discarded – undo
89 89
     {
90 90
         // Initial Setting for saving
91 91
         $this->_BIG_BLOCK_SIZE  = pow(2,
92
-                      ((isset($this->_BIG_BLOCK_SIZE))? $this->_adjust2($this->_BIG_BLOCK_SIZE)  : 9));
93
-        $this->_SMALL_BLOCK_SIZE= pow(2,
94
-                      ((isset($this->_SMALL_BLOCK_SIZE))?  $this->_adjust2($this->_SMALL_BLOCK_SIZE): 6));
92
+                      ((isset($this->_BIG_BLOCK_SIZE)) ? $this->_adjust2($this->_BIG_BLOCK_SIZE) : 9));
93
+        $this->_SMALL_BLOCK_SIZE = pow(2,
94
+                      ((isset($this->_SMALL_BLOCK_SIZE)) ? $this->_adjust2($this->_SMALL_BLOCK_SIZE) : 6));
95 95
 
96 96
         // Open temp file if we are sending output to stdout
97 97
         if (($filename == '-') || ($filename == '')) {
98 98
             $this->_tmp_filename = tempnam($this->_tmp_dir, "OLE_PPS_Root");
99
-            $this->_FILEH_ = @fopen($this->_tmp_filename,"w+b");
99
+            $this->_FILEH_ = @fopen($this->_tmp_filename, "w+b");
100 100
             if ($this->_FILEH_ == false) {
101 101
                 return $this->raiseError("Can't create temporary file.");
102 102
             }
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
     function _calcSize(&$raList)
148 148
     {
149 149
         // Calculate Basic Setting
150
-        list($iSBDcnt, $iBBcnt, $iPPScnt) = array(0,0,0);
150
+        list($iSBDcnt, $iBBcnt, $iPPScnt) = array(0, 0, 0);
151 151
         $iSmallLen = 0;
152 152
         $iSBcnt = 0;
153 153
         for ($i = 0; $i < count($raList); $i++) {
@@ -155,21 +155,21 @@  discard block
 block discarded – undo
155 155
                 $raList[$i]->Size = $raList[$i]->_DataLen();
156 156
                 if ($raList[$i]->Size < OLE_DATA_SIZE_SMALL) {
157 157
                     $iSBcnt += floor($raList[$i]->Size / $this->_SMALL_BLOCK_SIZE)
158
-                                  + (($raList[$i]->Size % $this->_SMALL_BLOCK_SIZE)? 1: 0);
158
+                                  + (($raList[$i]->Size % $this->_SMALL_BLOCK_SIZE) ? 1 : 0);
159 159
                 } else {
160 160
                     $iBBcnt += (floor($raList[$i]->Size / $this->_BIG_BLOCK_SIZE) +
161
-                        (($raList[$i]->Size % $this->_BIG_BLOCK_SIZE)? 1: 0));
161
+                        (($raList[$i]->Size % $this->_BIG_BLOCK_SIZE) ? 1 : 0));
162 162
                 }
163 163
             }
164 164
         }
165 165
         $iSmallLen = $iSBcnt * $this->_SMALL_BLOCK_SIZE;
166 166
         $iSlCnt = floor($this->_BIG_BLOCK_SIZE / OLE_LONG_INT_SIZE);
167
-        $iSBDcnt = floor($iSBcnt / $iSlCnt) + (($iSBcnt % $iSlCnt)? 1:0);
168
-        $iBBcnt +=  (floor($iSmallLen / $this->_BIG_BLOCK_SIZE) +
169
-                      (( $iSmallLen % $this->_BIG_BLOCK_SIZE)? 1: 0));
167
+        $iSBDcnt = floor($iSBcnt / $iSlCnt) + (($iSBcnt % $iSlCnt) ? 1 : 0);
168
+        $iBBcnt += (floor($iSmallLen / $this->_BIG_BLOCK_SIZE) +
169
+                      (($iSmallLen % $this->_BIG_BLOCK_SIZE) ? 1 : 0));
170 170
         $iCnt = count($raList);
171 171
         $iBdCnt = $this->_BIG_BLOCK_SIZE / OLE_PPS_SIZE;
172
-        $iPPScnt = (floor($iCnt/$iBdCnt) + (($iCnt % $iBdCnt)? 1: 0));
172
+        $iPPScnt = (floor($iCnt / $iBdCnt) + (($iCnt % $iBdCnt) ? 1 : 0));
173 173
 
174 174
         return array($iSBDcnt, $iBBcnt, $iPPScnt);
175 175
     }
@@ -184,8 +184,8 @@  discard block
 block discarded – undo
184 184
     */
185 185
     function _adjust2($i2)
186 186
     {
187
-        $iWk = log($i2)/log(2);
188
-        return ($iWk > floor($iWk))? floor($iWk)+1:$iWk;
187
+        $iWk = log($i2) / log(2);
188
+        return ($iWk > floor($iWk)) ? floor($iWk) + 1 : $iWk;
189 189
     }
190 190
 
191 191
     /**
@@ -207,17 +207,17 @@  discard block
 block discarded – undo
207 207
         $iBdExL = 0;
208 208
         $iAll = $iBBcnt + $iPPScnt + $iSBDcnt;
209 209
         $iAllW = $iAll;
210
-        $iBdCntW = floor($iAllW / $iBlCnt) + (($iAllW % $iBlCnt)? 1: 0);
211
-        $iBdCnt = floor(($iAll + $iBdCntW) / $iBlCnt) + ((($iAllW+$iBdCntW) % $iBlCnt)? 1: 0);
210
+        $iBdCntW = floor($iAllW / $iBlCnt) + (($iAllW % $iBlCnt) ? 1 : 0);
211
+        $iBdCnt = floor(($iAll + $iBdCntW) / $iBlCnt) + ((($iAllW + $iBdCntW) % $iBlCnt) ? 1 : 0);
212 212
 
213 213
         // Calculate BD count
214 214
         if ($iBdCnt > $i1stBdL) {
215 215
             while (1) {
216 216
                 $iBdExL++;
217 217
                 $iAllW++;
218
-                $iBdCntW = floor($iAllW / $iBlCnt) + (($iAllW % $iBlCnt)? 1: 0);
219
-                $iBdCnt = floor(($iAllW + $iBdCntW) / $iBlCnt) + ((($iAllW+$iBdCntW) % $iBlCnt)? 1: 0);
220
-                if ($iBdCnt <= ($iBdExL*$iBlCnt+ $i1stBdL)) {
218
+                $iBdCntW = floor($iAllW / $iBlCnt) + (($iAllW % $iBlCnt) ? 1 : 0);
219
+                $iBdCnt = floor(($iAllW + $iBdCntW) / $iBlCnt) + ((($iAllW + $iBdCntW) % $iBlCnt) ? 1 : 0);
220
+                if ($iBdCnt <= ($iBdExL * $iBlCnt + $i1stBdL)) {
221 221
                     break;
222 222
                 }
223 223
             }
@@ -239,7 +239,7 @@  discard block
 block discarded – undo
239 239
                   . "\x00\x00\x00\x00"
240 240
                   . "\x00\x00\x00\x00"
241 241
                   . pack("V", $iBdCnt)
242
-                  . pack("V", $iBBcnt+$iSBDcnt) //ROOT START
242
+                  . pack("V", $iBBcnt + $iSBDcnt) //ROOT START
243 243
                   . pack("V", 0)
244 244
                   . pack("V", 0x1000)
245 245
                   . pack("V", 0)                  //Small Block Depot
@@ -248,19 +248,19 @@  discard block
 block discarded – undo
248 248
         // Extra BDList Start, Count
249 249
         if ($iBdCnt < $i1stBdL) {
250 250
             fwrite($FILE,
251
-                      pack("V", -2).      // Extra BDList Start
251
+                      pack("V", -2).// Extra BDList Start
252 252
                       pack("V", 0)        // Extra BDList Count
253 253
                   );
254 254
         } else {
255
-            fwrite($FILE, pack("V", $iAll+$iBdCnt) . pack("V", $iBdExL));
255
+            fwrite($FILE, pack("V", $iAll + $iBdCnt).pack("V", $iBdExL));
256 256
         }
257 257
 
258 258
         // BDList
259 259
         for ($i = 0; $i < $i1stBdL && $i < $iBdCnt; $i++) {
260
-            fwrite($FILE, pack("V", $iAll+$i));
260
+            fwrite($FILE, pack("V", $iAll + $i));
261 261
         }
262 262
         if ($i < $i1stBdL) {
263
-            for ($j = 0; $j < ($i1stBdL-$i); $j++) {
263
+            for ($j = 0; $j < ($i1stBdL - $i); $j++) {
264 264
                 fwrite($FILE, (pack("V", -1)));
265 265
             }
266 266
         }
@@ -288,7 +288,7 @@  discard block
 block discarded – undo
288 288
                     if (isset($raList[$i]->_PPS_FILE)) {
289 289
                         $iLen = 0;
290 290
                         fseek($raList[$i]->_PPS_FILE, 0); // To The Top
291
-                        while($sBuff = fread($raList[$i]->_PPS_FILE, 4096)) {
291
+                        while ($sBuff = fread($raList[$i]->_PPS_FILE, 4096)) {
292 292
                             $iLen += strlen($sBuff);
293 293
                             fwrite($FILE, $sBuff);
294 294
                         }
@@ -305,7 +305,7 @@  discard block
 block discarded – undo
305 305
                     $raList[$i]->_StartBlock = $iStBlk;
306 306
                     $iStBlk +=
307 307
                             (floor($raList[$i]->Size / $this->_BIG_BLOCK_SIZE) +
308
-                                (($raList[$i]->Size % $this->_BIG_BLOCK_SIZE)? 1: 0));
308
+                                (($raList[$i]->Size % $this->_BIG_BLOCK_SIZE) ? 1 : 0));
309 309
                 }
310 310
                 // Close file for each PPS, and unlink it
311 311
                 if (isset($raList[$i]->_PPS_FILE)) {
@@ -337,10 +337,10 @@  discard block
 block discarded – undo
337 337
                 }
338 338
                 if ($raList[$i]->Size < OLE_DATA_SIZE_SMALL) {
339 339
                     $iSmbCnt = floor($raList[$i]->Size / $this->_SMALL_BLOCK_SIZE)
340
-                                  + (($raList[$i]->Size % $this->_SMALL_BLOCK_SIZE)? 1: 0);
340
+                                  + (($raList[$i]->Size % $this->_SMALL_BLOCK_SIZE) ? 1 : 0);
341 341
                     // Add to SBD
342
-                    for ($j = 0; $j < ($iSmbCnt-1); $j++) {
343
-                        fwrite($FILE, pack("V", $j+$iSmBlk+1));
342
+                    for ($j = 0; $j < ($iSmbCnt - 1); $j++) {
343
+                        fwrite($FILE, pack("V", $j + $iSmBlk + 1));
344 344
                     }
345 345
                     fwrite($FILE, pack("V", -2));
346 346
 
@@ -413,16 +413,16 @@  discard block
 block discarded – undo
413 413
         $iBdExL = 0;
414 414
         $iAll = $iBsize + $iPpsCnt + $iSbdSize;
415 415
         $iAllW = $iAll;
416
-        $iBdCntW = floor($iAllW / $iBbCnt) + (($iAllW % $iBbCnt)? 1: 0);
417
-        $iBdCnt = floor(($iAll + $iBdCntW) / $iBbCnt) + ((($iAllW+$iBdCntW) % $iBbCnt)? 1: 0);
416
+        $iBdCntW = floor($iAllW / $iBbCnt) + (($iAllW % $iBbCnt) ? 1 : 0);
417
+        $iBdCnt = floor(($iAll + $iBdCntW) / $iBbCnt) + ((($iAllW + $iBdCntW) % $iBbCnt) ? 1 : 0);
418 418
         // Calculate BD count
419
-        if ($iBdCnt >$i1stBdL) {
419
+        if ($iBdCnt > $i1stBdL) {
420 420
             while (1) {
421 421
                 $iBdExL++;
422 422
                 $iAllW++;
423
-                $iBdCntW = floor($iAllW / $iBbCnt) + (($iAllW % $iBbCnt)? 1: 0);
424
-                $iBdCnt = floor(($iAllW + $iBdCntW) / $iBbCnt) + ((($iAllW+$iBdCntW) % $iBbCnt)? 1: 0);
425
-                if ($iBdCnt <= ($iBdExL*$iBbCnt+ $i1stBdL)) {
423
+                $iBdCntW = floor($iAllW / $iBbCnt) + (($iAllW % $iBbCnt) ? 1 : 0);
424
+                $iBdCnt = floor(($iAllW + $iBdCntW) / $iBbCnt) + ((($iAllW + $iBdCntW) % $iBbCnt) ? 1 : 0);
425
+                if ($iBdCnt <= ($iBdExL * $iBbCnt + $i1stBdL)) {
426 426
                     break;
427 427
                 }
428 428
             }
@@ -432,19 +432,19 @@  discard block
 block discarded – undo
432 432
         // Set for SBD
433 433
         if ($iSbdSize > 0) {
434 434
             for ($i = 0; $i < ($iSbdSize - 1); $i++) {
435
-                fwrite($FILE, pack("V", $i+1));
435
+                fwrite($FILE, pack("V", $i + 1));
436 436
             }
437 437
             fwrite($FILE, pack("V", -2));
438 438
         }
439 439
         // Set for B
440 440
         for ($i = 0; $i < ($iBsize - 1); $i++) {
441
-            fwrite($FILE, pack("V", $i+$iSbdSize+1));
441
+            fwrite($FILE, pack("V", $i + $iSbdSize + 1));
442 442
         }
443 443
         fwrite($FILE, pack("V", -2));
444 444
 
445 445
         // Set for PPS
446 446
         for ($i = 0; $i < ($iPpsCnt - 1); $i++) {
447
-            fwrite($FILE, pack("V", $i+$iSbdSize+$iBsize+1));
447
+            fwrite($FILE, pack("V", $i + $iSbdSize + $iBsize + 1));
448 448
         }
449 449
         fwrite($FILE, pack("V", -2));
450 450
         // Set for BBD itself ( 0xFFFFFFFD : BBD)
@@ -463,17 +463,17 @@  discard block
 block discarded – undo
463 463
         }
464 464
         // Extra BDList
465 465
         if ($iBdCnt > $i1stBdL) {
466
-            $iN=0;
467
-            $iNb=0;
468
-            for ($i = $i1stBdL;$i < $iBdCnt; $i++, $iN++) {
466
+            $iN = 0;
467
+            $iNb = 0;
468
+            for ($i = $i1stBdL; $i < $iBdCnt; $i++, $iN++) {
469 469
                 if ($iN >= ($iBbCnt - 1)) {
470 470
                     $iN = 0;
471 471
                     $iNb++;
472
-                    fwrite($FILE, pack("V", $iAll+$iBdCnt+$iNb));
472
+                    fwrite($FILE, pack("V", $iAll + $iBdCnt + $iNb));
473 473
                 }
474
-                fwrite($FILE, pack("V", $iBsize+$iSbdSize+$iPpsCnt+$i));
474
+                fwrite($FILE, pack("V", $iBsize + $iSbdSize + $iPpsCnt + $i));
475 475
             }
476
-            if (($iBdCnt-$i1stBdL) % ($iBbCnt-1)) {
476
+            if (($iBdCnt - $i1stBdL) % ($iBbCnt - 1)) {
477 477
                 for ($i = 0; $i < (($iBbCnt - 1) - (($iBdCnt - $i1stBdL) % ($iBbCnt - 1))); $i++) {
478 478
                     fwrite($FILE, pack("V", -1));
479 479
                 }
Please login to merge, or discard this patch.
main/inc/lib/pear/OLE/OLE.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -23,12 +23,12 @@  discard block
 block discarded – undo
23 23
 /**
24 24
 * Constants for OLE package
25 25
 */
26
-define('OLE_PPS_TYPE_ROOT',        5);
27
-define('OLE_PPS_TYPE_DIR',         1);
28
-define('OLE_PPS_TYPE_FILE',        2);
26
+define('OLE_PPS_TYPE_ROOT', 5);
27
+define('OLE_PPS_TYPE_DIR', 1);
28
+define('OLE_PPS_TYPE_FILE', 2);
29 29
 define('OLE_DATA_SIZE_SMALL', 0x1000);
30
-define('OLE_LONG_INT_SIZE',        4);
31
-define('OLE_PPS_SIZE',          0x80);
30
+define('OLE_LONG_INT_SIZE', 4);
31
+define('OLE_PPS_SIZE', 0x80);
32 32
 
33 33
 /**
34 34
 * Array for storing OLE instances that are accessed from
@@ -183,7 +183,7 @@  discard block
 block discarded – undo
183 183
         for ($i = 0; $i < $bbatBlockCount; $i++) {
184 184
             $pos = $this->_getBlockOffset($mbatBlocks[$i]);
185 185
             fseek($fh, $pos);
186
-            for ($j = 0 ; $j < $this->bigBlockSize / 4; $j++) {
186
+            for ($j = 0; $j < $this->bigBlockSize / 4; $j++) {
187 187
                 $this->bbat[] = $this->_readInt4($fh);
188 188
             }
189 189
         }
@@ -234,12 +234,12 @@  discard block
 block discarded – undo
234 234
         $GLOBALS['_OLE_INSTANCES'][] = $this;
235 235
         $instanceId = end(array_keys($GLOBALS['_OLE_INSTANCES']));
236 236
 
237
-        $path = 'ole-chainedblockstream://oleInstanceId=' . $instanceId;
237
+        $path = 'ole-chainedblockstream://oleInstanceId='.$instanceId;
238 238
         if (is_a($blockIdOrPps, 'OLE_PPS')) {
239
-            $path .= '&blockId=' . $blockIdOrPps->_StartBlock;
240
-            $path .= '&size=' . $blockIdOrPps->Size;
239
+            $path .= '&blockId='.$blockIdOrPps->_StartBlock;
240
+            $path .= '&size='.$blockIdOrPps->Size;
241 241
         } else {
242
-            $path .= '&blockId=' . $blockIdOrPps;
242
+            $path .= '&blockId='.$blockIdOrPps;
243 243
         }
244 244
         return fopen($path, 'r');
245 245
     }
@@ -472,7 +472,7 @@  discard block
 block discarded – undo
472 472
     {
473 473
         $rawname = '';
474 474
         for ($i = 0; $i < strlen($ascii); $i++) {
475
-            $rawname .= $ascii{$i} . "\x00";
475
+            $rawname .= $ascii{$i}."\x00";
476 476
         }
477 477
         return $rawname;
478 478
     }
@@ -499,8 +499,8 @@  discard block
 block discarded – undo
499 499
         $days = 134774;
500 500
         // calculate seconds
501 501
         $big_date = $days * 24 * 3600 +
502
-            gmmktime(date("H",$date),date("i",$date),date("s",$date),
503
-                     date("m",$date),date("d",$date),date("Y",$date));
502
+            gmmktime(date("H", $date), date("i", $date), date("s", $date),
503
+                     date("m", $date), date("d", $date), date("Y", $date));
504 504
         // multiply just to make MS happy
505 505
         $big_date *= 10000000;
506 506
 
@@ -538,7 +538,7 @@  discard block
 block discarded – undo
538 538
         }
539 539
 
540 540
         // factor used for separating numbers into 4 bytes parts
541
-        $factor = pow(2,32);
541
+        $factor = pow(2, 32);
542 542
         $high_part = 0;
543 543
         for ($i = 0; $i < 4; $i++) {
544 544
             list(, $high_part) = unpack('C', $string{(7 - $i)});
Please login to merge, or discard this patch.
main/inc/lib/pear/OLE/PPS.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -189,10 +189,10 @@
 block discarded – undo
189 189
               . "\x00\x00\x00\x00"                  // 100
190 190
               . OLE::LocalDate2OLE($this->Time1st)       // 108
191 191
               . OLE::LocalDate2OLE($this->Time2nd)       // 116
192
-              . pack("V", isset($this->_StartBlock)?
193
-                        $this->_StartBlock:0)        // 120
192
+              . pack("V", isset($this->_StartBlock) ?
193
+                        $this->_StartBlock : 0)        // 120
194 194
               . pack("V", $this->Size)               // 124
195
-              . pack("V", 0);                        // 128
195
+              . pack("V", 0); // 128
196 196
         return $ret;
197 197
     }
198 198
 
Please login to merge, or discard this patch.
main/inc/lib/pear/Text/CAPTCHA.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
     public static function factory($driver)
77 77
     {
78 78
         $driver = basename($driver);
79
-        $class = 'Text_CAPTCHA_Driver_' . $driver;
79
+        $class = 'Text_CAPTCHA_Driver_'.$driver;
80 80
         /*$file = str_replace('_', '/', $class) . '.php';
81 81
         //check if it exists and can be loaded
82 82
         if (!@fclose(@fopen($file, 'r', true))) {
Please login to merge, or discard this patch.
main/inc/lib/pear/Text/CAPTCHA/Driver/Word.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
             $this->_length = 4;
71 71
         }
72 72
         if (isset($options['phrase']) && !empty($options['phrase'])) {
73
-            $this->setPhrase((string)$options['phrase']);
73
+            $this->setPhrase((string) $options['phrase']);
74 74
         } else {
75 75
             $this->createPhrase();
76 76
         }
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
         if ($this->_mode == 'single') {
117 117
             $phraseArr = str_split($phrase);
118 118
             for ($i = 0; $i < strlen($phrase); $i++) {
119
-                $res .= ' ' . $numberWords->toWords($phraseArr[$i], $this->_locale);
119
+                $res .= ' '.$numberWords->toWords($phraseArr[$i], $this->_locale);
120 120
             }
121 121
         } else {
122 122
             $res = $numberWords->toWords($phrase, $this->_locale);
Please login to merge, or discard this patch.
main/inc/lib/pear/Text/CAPTCHA/Driver/Figlet.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -80,13 +80,13 @@  discard block
 block discarded – undo
80 80
     public function initDriver($options = array())
81 81
     {
82 82
         if (!empty($options['output'])) {
83
-            $this->_output = (string)$options['output'];
83
+            $this->_output = (string) $options['output'];
84 84
         } else {
85 85
             $this->_output = 'html';
86 86
         }
87 87
 
88 88
         if (isset($options['width']) && $options['width']) {
89
-            $this->_width = (int)$options['width'];
89
+            $this->_width = (int) $options['width'];
90 90
         } else {
91 91
             $this->_width = 200;
92 92
         }
@@ -201,11 +201,11 @@  discard block
 block discarded – undo
201 201
         }
202 202
 
203 203
         $htmlOutput = '<div style="font-family: courier;
204
-          font-size: ' . $textSize . 'px;
205
-          width:' . $this->_width . 'px;
204
+          font-size: ' . $textSize.'px;
205
+          width:' . $this->_width.'px;
206 206
           text-align:center;">';
207
-        $htmlOutput .= '<div style="' . $cssOutput . 'margin:0px;">
208
-          <pre style="padding: 0px; margin: 0px;">' . $data . '</pre></div></div>';
207
+        $htmlOutput .= '<div style="'.$cssOutput.'margin:0px;">
208
+          <pre style="padding: 0px; margin: 0px;">' . $data.'</pre></div></div>';
209 209
 
210 210
         return $htmlOutput;
211 211
     }
Please login to merge, or discard this patch.
main/inc/lib/pear/Text/CAPTCHA/Driver/Equation.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -97,27 +97,27 @@  discard block
 block discarded – undo
97 97
     public function initDriver($options = array())
98 98
     {
99 99
         if (isset($options['min'])) {
100
-            $this->_min = (int)$options['min'];
100
+            $this->_min = (int) $options['min'];
101 101
         } else {
102 102
             $this->_min = 1;
103 103
         }
104 104
         if (isset($options['max'])) {
105
-            $this->_max = (int)$options['max'];
105
+            $this->_max = (int) $options['max'];
106 106
         } else {
107 107
             $this->_max = 10;
108 108
         }
109 109
         if (isset($options['numbersToText'])) {
110
-            $this->_numbersToText = (bool)$options['numbersToText'];
110
+            $this->_numbersToText = (bool) $options['numbersToText'];
111 111
         } else {
112 112
             $this->_numbersToText = false;
113 113
         }
114 114
         if (isset($options['locale'])) {
115
-            $this->_locale = (string)$options['locale'];
115
+            $this->_locale = (string) $options['locale'];
116 116
         } else {
117 117
             $this->_locale = '';
118 118
         }
119 119
         if (isset($options['severity'])) {
120
-            $this->_severity = (int)$options['severity'];
120
+            $this->_severity = (int) $options['severity'];
121 121
         } else {
122 122
             $this->_severity = 1;
123 123
         }
@@ -148,11 +148,11 @@  discard block
 block discarded – undo
148 148
             list($eq2, $sol2) = $this->_createSimpleEquation();
149 149
             $op3 = $this->_operators[mt_rand(0, count($this->_operators) - 1)];
150 150
             list(, $phrase) = $this->_solveSimpleEquation($sol1, $sol2, $op3);
151
-            $equation = sprintf($op3, '(' . $eq1 . ')', '(' . $eq2 . ')');
151
+            $equation = sprintf($op3, '('.$eq1.')', '('.$eq2.')');
152 152
             break;
153 153
         default:
154 154
             throw new Text_CAPTCHA_Exception(
155
-                'Equation complexity of ' . $this->_severity . ' not supported'
155
+                'Equation complexity of '.$this->_severity.' not supported'
156 156
             );
157 157
         }
158 158
         $this->setCaptcha($equation);
@@ -188,7 +188,7 @@  discard block
 block discarded – undo
188 188
     {
189 189
         $equation = sprintf($operator, $one, $two);
190 190
 
191
-        $function = create_function('', 'return ' . $equation . ';');
191
+        $function = create_function('', 'return '.$equation.';');
192 192
 
193 193
         if ($this->_numbersToText) {
194 194
             $numberWords = new Numbers_Words();
Please login to merge, or discard this patch.
main/inc/lib/pear/Text/CAPTCHA/Driver/Numeral.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -88,12 +88,12 @@  discard block
 block discarded – undo
88 88
     public function initDriver($options = array())
89 89
     {
90 90
         if (isset($options['minValue'])) {
91
-            $this->_minValue = (int)$options['minValue'];
91
+            $this->_minValue = (int) $options['minValue'];
92 92
         } else {
93 93
             $this->_minValue = 1;
94 94
         }
95 95
         if (isset($options['maxValue'])) {
96
-            $this->_maxValue = (int)$options['maxValue'];
96
+            $this->_maxValue = (int) $options['maxValue'];
97 97
         } else {
98 98
             $this->_maxValue = 50;
99 99
         }
@@ -103,12 +103,12 @@  discard block
 block discarded – undo
103 103
             $this->_operator = '';
104 104
         }
105 105
         if (isset($options['firstValue'])) {
106
-            $this->_firstNumber = (int)$options['firstValue'];
106
+            $this->_firstNumber = (int) $options['firstValue'];
107 107
         } else {
108 108
             $this->_firstNumber = 0;
109 109
         }
110 110
         if (isset($options['secondValue'])) {
111
-            $this->_secondNumber = (int)$options['secondValue'];
111
+            $this->_secondNumber = (int) $options['secondValue'];
112 112
         } else {
113 113
             $this->_secondNumber = 0;
114 114
         }
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
     private function _setOperation()
156 156
     {
157 157
         $this->setCaptcha(
158
-            $this->_firstNumber . ' ' . $this->_operator . ' ' . $this->_secondNumber
158
+            $this->_firstNumber.' '.$this->_operator.' '.$this->_secondNumber
159 159
         );
160 160
     }
161 161
 
Please login to merge, or discard this patch.