@@ -28,12 +28,12 @@ |
||
28 | 28 | return false; |
29 | 29 | } |
30 | 30 | |
31 | - public function getMemberUids($recursive=true) |
|
31 | + public function getMemberUids($recursive = true) |
|
32 | 32 | { |
33 | 33 | return $this->members(false, $recursive, true); |
34 | 34 | } |
35 | 35 | |
36 | - public function members($details=false, $recursive=true, $includeGroups=true) |
|
36 | + public function members($details = false, $recursive = true, $includeGroups = true) |
|
37 | 37 | { |
38 | 38 | //TODO |
39 | 39 | return array(); |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | } |
21 | 21 | if(!is_int($algo)) |
22 | 22 | { |
23 | - trigger_error("password_hash() expects parameter 2 to be long, " . gettype($algo) . " given", E_USER_WARNING); |
|
23 | + trigger_error("password_hash() expects parameter 2 to be long, ".gettype($algo)." given", E_USER_WARNING); |
|
24 | 24 | return false; |
25 | 25 | } |
26 | 26 | $resultLength = 0; |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | $base64String = base64_encode($salt); |
44 | 44 | $salt = strtr(rtrim($base64String, '='), $base64Digits, $bcrypt64Digits); |
45 | 45 | $salt = substr($salt, 0, $requiredSaltLen); |
46 | - $hash = $hashFormat . $salt; |
|
46 | + $hash = $hashFormat.$salt; |
|
47 | 47 | $ret = crypt($password, $hash); |
48 | 48 | if(!is_string($ret) || strlen($ret) != $resultLength) |
49 | 49 | { |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | return \DataSetFactory::getDataSetByName('pending_authentication'); |
115 | 115 | } |
116 | 116 | |
117 | - private function getDataTable($name, $pending=false) |
|
117 | + private function getDataTable($name, $pending = false) |
|
118 | 118 | { |
119 | 119 | if(isset($this->dataTables[$name]) && isset($this->dataTables[$name][$pending])) |
120 | 120 | { |
@@ -227,12 +227,12 @@ discard block |
||
227 | 227 | return $data; |
228 | 228 | } |
229 | 229 | |
230 | - public function getGroupsByFilter($filter, $select=false, $top=false, $skip=false, $orderby=false) |
|
230 | + public function getGroupsByFilter($filter, $select = false, $top = false, $skip = false, $orderby = false) |
|
231 | 231 | { |
232 | 232 | return $this->convertDataToClass('group', 'SQLGroup', $filter, $select, $top, $skip, $orderby); |
233 | 233 | } |
234 | 234 | |
235 | - public function getUsersByFilter($filter, $select=false, $top=false, $skip=false, $orderby=false) |
|
235 | + public function getUsersByFilter($filter, $select = false, $top = false, $skip = false, $orderby = false) |
|
236 | 236 | { |
237 | 237 | return $this->convertDataToClass('group', 'SQLUser', $filter, $select, $top, $skip, $orderby); |
238 | 238 | } |
@@ -249,7 +249,7 @@ discard block |
||
249 | 249 | { |
250 | 250 | $userDataTable = $this->getPendingUserDataTable(); |
251 | 251 | $fieldData = $filter->to_mongo_filter(); |
252 | - $firstFilter = new \Data\Filter('substringof(data,"'.implode($fieldData,' ').'")'); |
|
252 | + $firstFilter = new \Data\Filter('substringof(data,"'.implode($fieldData, ' ').'")'); |
|
253 | 253 | $users = $userDataTable->read($firstFilter, $select, $top, $skip, $orderby); |
254 | 254 | if($users === false) |
255 | 255 | { |
@@ -276,7 +276,7 @@ discard block |
||
276 | 276 | return $ret; |
277 | 277 | } |
278 | 278 | |
279 | - public function getPendingUsersByFilter($filter, $select=false, $top=false, $skip=false, $orderby=false) |
|
279 | + public function getPendingUsersByFilter($filter, $select = false, $top = false, $skip = false, $orderby = false) |
|
280 | 280 | |
281 | 281 | { |
282 | 282 | if($this->pending === false) return false; |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | private $ldapObj; |
9 | 9 | private $server; |
10 | 10 | |
11 | - public function __construct($data=false) |
|
11 | + public function __construct($data = false) |
|
12 | 12 | { |
13 | 13 | $this->server = \LDAP\LDAPServer::getInstance(); |
14 | 14 | if($data !== false && !isset($data['dn']) && !isset($data['extended'])) |
@@ -220,9 +220,9 @@ discard block |
||
220 | 220 | |
221 | 221 | private function generateLDAPPass($pass) |
222 | 222 | { |
223 | - mt_srand((double)microtime()*1000000); |
|
223 | + mt_srand((double)microtime() * 1000000); |
|
224 | 224 | $salt = pack("CCCC", mt_rand(), mt_rand(), mt_rand(), mt_rand()); |
225 | - $hash = base64_encode(pack('H*',sha1($pass.$salt)).$salt); |
|
225 | + $hash = base64_encode(pack('H*', sha1($pass.$salt)).$salt); |
|
226 | 226 | return '{SSHA}'.$hash; |
227 | 227 | } |
228 | 228 | |
@@ -230,7 +230,7 @@ discard block |
||
230 | 230 | { |
231 | 231 | if(!is_object($this->ldapObj)) |
232 | 232 | { |
233 | - return $this->setFieldLocal('userPassword', $this->generateLDAPPass($password)); |
|
233 | + return $this->setFieldLocal('userPassword', $this->generateLDAPPass($password)); |
|
234 | 234 | } |
235 | 235 | else |
236 | 236 | { |
@@ -266,7 +266,7 @@ discard block |
||
266 | 266 | return false; |
267 | 267 | } |
268 | 268 | |
269 | - static function from_name($name, $data=false) |
|
269 | + static function from_name($name, $data = false) |
|
270 | 270 | { |
271 | 271 | if($data === false) |
272 | 272 | { |
@@ -281,7 +281,7 @@ discard block |
||
281 | 281 | return new static($user[0]); |
282 | 282 | } |
283 | 283 | |
284 | - static function from_dn($dn, $data=false) |
|
284 | + static function from_dn($dn, $data = false) |
|
285 | 285 | { |
286 | 286 | if($data === false) |
287 | 287 | { |
@@ -23,12 +23,12 @@ discard block |
||
23 | 23 | return false; |
24 | 24 | } |
25 | 25 | |
26 | - public function getMemberUids($recursive=true) |
|
26 | + public function getMemberUids($recursive = true) |
|
27 | 27 | { |
28 | 28 | return array(); |
29 | 29 | } |
30 | 30 | |
31 | - public function members($details=false, $recursive=true, $includeGroups=true) |
|
31 | + public function members($details = false, $recursive = true, $includeGroups = true) |
|
32 | 32 | { |
33 | 33 | return array(); |
34 | 34 | } |
@@ -46,20 +46,20 @@ discard block |
||
46 | 46 | public function jsonSerialize() |
47 | 47 | { |
48 | 48 | $group = array(); |
49 | - try{ |
|
49 | + try { |
|
50 | 50 | $group['cn'] = $this->getGroupName(); |
51 | 51 | $group['description'] = $this->getDescription(); |
52 | 52 | $group['member'] = $this->getMemberUids(); |
53 | - } catch(\Exception $e) {echo $e->getMessage(); die();} |
|
53 | + } catch(\Exception $e) {echo $e->getMessage(); die(); } |
|
54 | 54 | return $group; |
55 | 55 | } |
56 | 56 | |
57 | - public function getNonMembers($select=false) |
|
57 | + public function getNonMembers($select = false) |
|
58 | 58 | { |
59 | 59 | return array(); |
60 | 60 | } |
61 | 61 | |
62 | - public function addMember($name, $isGroup=false, $flush=true) |
|
62 | + public function addMember($name, $isGroup = false, $flush = true) |
|
63 | 63 | { |
64 | 64 | return false; |
65 | 65 | } |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | return true; |
102 | 102 | } |
103 | 103 | |
104 | - static function from_name($name, $data=false) |
|
104 | + static function from_name($name, $data = false) |
|
105 | 105 | { |
106 | 106 | return false; |
107 | 107 | } |
@@ -22,11 +22,11 @@ |
||
22 | 22 | $classname = ltrim($classname, '\\'); |
23 | 23 | $filename = ''; |
24 | 24 | $namespace = ''; |
25 | - if ($lastNsPos = strrpos($classname, '\\')) |
|
25 | + if($lastNsPos = strrpos($classname, '\\')) |
|
26 | 26 | { |
27 | 27 | $namespace = substr($classname, 0, $lastNsPos); |
28 | 28 | $classname = substr($classname, $lastNsPos + 1); |
29 | - $filename = str_replace('\\', DIRECTORY_SEPARATOR, $namespace) . DIRECTORY_SEPARATOR; |
|
29 | + $filename = str_replace('\\', DIRECTORY_SEPARATOR, $namespace).DIRECTORY_SEPARATOR; |
|
30 | 30 | } |
31 | 31 | $filename = __DIR__.DIRECTORY_SEPARATOR.$filename.'class.'.$classname.'.php'; |
32 | 32 | if(is_readable($filename)) |
@@ -30,32 +30,32 @@ discard block |
||
30 | 30 | */ |
31 | 31 | require_once('class.WebPage.php'); |
32 | 32 | |
33 | -define('JS_JQUERY', 0); |
|
34 | -define('JS_JQUERY_UI', 1); |
|
35 | -define('JS_BOOTSTRAP', 2); |
|
33 | +define('JS_JQUERY', 0); |
|
34 | +define('JS_JQUERY_UI', 1); |
|
35 | +define('JS_BOOTSTRAP', 2); |
|
36 | 36 | define('JQUERY_VALIDATE', 3); |
37 | -define('JQUERY_TOUCH', 4); |
|
38 | -define('JS_TINYNAV', 5); |
|
37 | +define('JQUERY_TOUCH', 4); |
|
38 | +define('JS_TINYNAV', 5); |
|
39 | 39 | define('JS_BOOTSTRAP_FH', 6); |
40 | 40 | define('JS_BOOTSTRAP_SW', 7); |
41 | -define('JS_DATATABLE', 8); |
|
42 | -define('JS_CHART', 9); |
|
43 | -define('JS_METISMENU', 10); |
|
44 | -define('JS_BOOTBOX', 11); |
|
41 | +define('JS_DATATABLE', 8); |
|
42 | +define('JS_CHART', 9); |
|
43 | +define('JS_METISMENU', 10); |
|
44 | +define('JS_BOOTBOX', 11); |
|
45 | 45 | define('JS_DATATABLE_ODATA', 12); |
46 | -define('JS_CRYPTO_MD5_JS', 13); |
|
47 | -define('JS_JCROP', 14); |
|
48 | -define('JS_TYPEAHEAD', 15); |
|
49 | -define('JS_FLIPSIDE', 20); |
|
50 | -define('JS_LOGIN', 21); |
|
51 | - |
|
52 | -define('CSS_JQUERY_UI', 0); |
|
53 | -define('CSS_BOOTSTRAP', 1); |
|
46 | +define('JS_CRYPTO_MD5_JS', 13); |
|
47 | +define('JS_JCROP', 14); |
|
48 | +define('JS_TYPEAHEAD', 15); |
|
49 | +define('JS_FLIPSIDE', 20); |
|
50 | +define('JS_LOGIN', 21); |
|
51 | + |
|
52 | +define('CSS_JQUERY_UI', 0); |
|
53 | +define('CSS_BOOTSTRAP', 1); |
|
54 | 54 | define('CSS_BOOTSTRAP_FH', 2); |
55 | 55 | define('CSS_BOOTSTRAP_SW', 3); |
56 | -define('CSS_DATATABLE', 4); |
|
57 | -define('CSS_JCROP', 5); |
|
58 | -define('CSS_FONTAWESOME', 6); |
|
56 | +define('CSS_DATATABLE', 4); |
|
57 | +define('CSS_JCROP', 5); |
|
58 | +define('CSS_FONTAWESOME', 6); |
|
59 | 59 | |
60 | 60 | global $jsArray; |
61 | 61 | $jsArray = array( |
@@ -349,7 +349,7 @@ discard block |
||
349 | 349 | * |
350 | 350 | * @SuppressWarnings("StaticAccess") |
351 | 351 | */ |
352 | - function __construct($title, $header=true) |
|
352 | + function __construct($title, $header = true) |
|
353 | 353 | { |
354 | 354 | parent::__construct($title); |
355 | 355 | $this->setupVars(); |
@@ -447,7 +447,7 @@ discard block |
||
447 | 447 | * |
448 | 448 | * @deprecated 2.0.0 Please use addJSByURI() instead |
449 | 449 | */ |
450 | - function add_js_from_src($src, $async=true) |
|
450 | + function add_js_from_src($src, $async = true) |
|
451 | 451 | { |
452 | 452 | $this->addJSByURI($src, $async); |
453 | 453 | } |
@@ -458,7 +458,7 @@ discard block |
||
458 | 458 | * @param string $uri The webpath to the JavaScript file |
459 | 459 | * @param boolean $async Can the JavaScript be loaded asynchronously? |
460 | 460 | */ |
461 | - public function addJSByURI($uri, $async=true) |
|
461 | + public function addJSByURI($uri, $async = true) |
|
462 | 462 | { |
463 | 463 | $attributes = array('src'=>$uri, 'type'=>'text/javascript'); |
464 | 464 | if($async === true) |
@@ -479,7 +479,7 @@ discard block |
||
479 | 479 | * |
480 | 480 | * @deprecated 2.0.0 Please use addCSSByURI() instead |
481 | 481 | */ |
482 | - function add_css_from_src($src, $import=false) |
|
482 | + function add_css_from_src($src, $import = false) |
|
483 | 483 | { |
484 | 484 | $this->addCSSByURI($src, $import); |
485 | 485 | } |
@@ -490,7 +490,7 @@ discard block |
||
490 | 490 | * @param string $src The webpath to the Cascading Style Sheet file |
491 | 491 | * @param boolean $async Can the CSS be loaded asynchronously? |
492 | 492 | */ |
493 | - public function addCSSByURI($uri, $async=false) |
|
493 | + public function addCSSByURI($uri, $async = false) |
|
494 | 494 | { |
495 | 495 | $attributes = array('rel'=>'stylesheet', 'href'=>$uri, 'type'=>'text/css'); |
496 | 496 | if($async === true && $this->importSupport === true) |
@@ -509,12 +509,12 @@ discard block |
||
509 | 509 | * |
510 | 510 | * @deprecated 2.0.0 Please use addWellKnownJS() instead |
511 | 511 | */ |
512 | - function addJS($type, $async=true) |
|
512 | + function addJS($type, $async = true) |
|
513 | 513 | { |
514 | 514 | $this->addWellKnownJS($type, $async); |
515 | 515 | } |
516 | 516 | |
517 | - function add_js($type, $async=true) |
|
517 | + function add_js($type, $async = true) |
|
518 | 518 | { |
519 | 519 | $this->addWellKnownJS($type, $async); |
520 | 520 | } |
@@ -525,7 +525,7 @@ discard block |
||
525 | 525 | * @param string $jsFileID the ID of the JS file |
526 | 526 | * @param boolean $async Can the JS file be loaded asynchronously? |
527 | 527 | */ |
528 | - public function addWellKnownJS($jsFileID, $async=true) |
|
528 | + public function addWellKnownJS($jsFileID, $async = true) |
|
529 | 529 | { |
530 | 530 | global $jsArray; |
531 | 531 | $this->setupVars(); |
@@ -541,7 +541,7 @@ discard block |
||
541 | 541 | * |
542 | 542 | * @deprecated 2.0.0 Please use addWellKnownCSS() instead |
543 | 543 | */ |
544 | - function add_css($type, $import=false) |
|
544 | + function add_css($type, $import = false) |
|
545 | 545 | { |
546 | 546 | $this->addWellKnownCSS($type, $import); |
547 | 547 | } |
@@ -552,7 +552,7 @@ discard block |
||
552 | 552 | * @param string $cssFileID the ID of the CSS file |
553 | 553 | * @param boolean $async Can the CSS file be loaded asynchronously? |
554 | 554 | */ |
555 | - public function addWellKnownCSS($cssFileID, $async=true) |
|
555 | + public function addWellKnownCSS($cssFileID, $async = true) |
|
556 | 556 | { |
557 | 557 | global $cssArray; |
558 | 558 | $this->setupVars(); |
@@ -577,7 +577,7 @@ discard block |
||
577 | 577 | $ret = ''; |
578 | 578 | foreach($names as $name) |
579 | 579 | { |
580 | - $ret.='<li>'.$this->createLink($name, $sites[$name]).'</li>'; |
|
580 | + $ret .= '<li>'.$this->createLink($name, $sites[$name]).'</li>'; |
|
581 | 581 | } |
582 | 582 | return $ret; |
583 | 583 | } |
@@ -597,14 +597,14 @@ discard block |
||
597 | 597 | { |
598 | 598 | $ret = '<li class="dropdown">'; |
599 | 599 | $href = $this->getHrefForDropdown($link); |
600 | - $ret.= '<a href="'.$href.'" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">'.$name.' <span class="caret"></span></a>'; |
|
601 | - $ret.='<ul class="dropdown-menu">'; |
|
600 | + $ret .= '<a href="'.$href.'" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">'.$name.' <span class="caret"></span></a>'; |
|
601 | + $ret .= '<ul class="dropdown-menu">'; |
|
602 | 602 | $subNames = array_keys($link); |
603 | 603 | foreach($subNames as $subName) |
604 | 604 | { |
605 | - $ret.=$this->getLinkByName($subName, $link); |
|
605 | + $ret .= $this->getLinkByName($subName, $link); |
|
606 | 606 | } |
607 | - $ret.='</ul></li>'; |
|
607 | + $ret .= '</ul></li>'; |
|
608 | 608 | return $ret; |
609 | 609 | } |
610 | 610 | |
@@ -627,7 +627,7 @@ discard block |
||
627 | 627 | $ret = ''; |
628 | 628 | foreach($names as $name) |
629 | 629 | { |
630 | - $ret.=$this->getLinkByName($name, $this->links); |
|
630 | + $ret .= $this->getLinkByName($name, $this->links); |
|
631 | 631 | } |
632 | 632 | return $ret; |
633 | 633 | } |
@@ -639,7 +639,7 @@ discard block |
||
639 | 639 | { |
640 | 640 | $sites = $this->getSiteLinksForHeader(); |
641 | 641 | $links = $this->getLinksMenus(); |
642 | - $header ='<nav class="navbar navbar-default navbar-fixed-top"> |
|
642 | + $header = '<nav class="navbar navbar-default navbar-fixed-top"> |
|
643 | 643 | <div class="container-fluid"> |
644 | 644 | <!-- Brand and toggle get grouped for better mobile display --> |
645 | 645 | <div class="navbar-header"> |
@@ -668,7 +668,7 @@ discard block |
||
668 | 668 | </div> |
669 | 669 | </nav>'; |
670 | 670 | $this->body = $header.$this->body; |
671 | - $this->body_tags.='style="padding-top: 60px;"'; |
|
671 | + $this->body_tags .= 'style="padding-top: 60px;"'; |
|
672 | 672 | } |
673 | 673 | |
674 | 674 | /** Notification that is green for success */ |
@@ -689,7 +689,7 @@ discard block |
||
689 | 689 | * |
690 | 690 | * @deprecated 2.0.0 Use the addNotification function instead |
691 | 691 | */ |
692 | - function add_notification($msg, $sev=self::NOTIFICATION_INFO, $dismissible=1) |
|
692 | + function add_notification($msg, $sev = self::NOTIFICATION_INFO, $dismissible = 1) |
|
693 | 693 | { |
694 | 694 | $notice = array('msg'=>$msg, 'sev'=>$sev, 'dismissible'=>$dismissible); |
695 | 695 | array_push($this->notifications, $notice); |
@@ -702,7 +702,7 @@ discard block |
||
702 | 702 | * @param string $sevity The severity of the notifcation |
703 | 703 | * @param boolean $dismissible Can the user dismiss the notificaton? |
704 | 704 | */ |
705 | - public function addNotification($message, $severity=self::NOTIFICATION_INFO, $dismissible=true) |
|
705 | + public function addNotification($message, $severity = self::NOTIFICATION_INFO, $dismissible = true) |
|
706 | 706 | { |
707 | 707 | array_push($this->notifications, array('msg'=>$message, 'sev'=>$severity, 'dismissible'=>$dismissible)); |
708 | 708 | } |
@@ -740,10 +740,10 @@ discard block |
||
740 | 740 | break; |
741 | 741 | } |
742 | 742 | $style = ''; |
743 | - if($i+1 < count($this->notifications)) |
|
743 | + if($i + 1 < count($this->notifications)) |
|
744 | 744 | { |
745 | 745 | //Not the last notification, remove the end margin |
746 | - $style='style="margin: 0px;"'; |
|
746 | + $style = 'style="margin: 0px;"'; |
|
747 | 747 | } |
748 | 748 | $this->body = ' |
749 | 749 | <div class="'.$class.'" role="alert" '.$style.'> |
@@ -793,7 +793,7 @@ discard block |
||
793 | 793 | * @param boolean $header Draw the header |
794 | 794 | * @param boolean $analytics Include analytics on the page |
795 | 795 | */ |
796 | - public function printPage($header=true) |
|
796 | + public function printPage($header = true) |
|
797 | 797 | { |
798 | 798 | $this->renderNotifications(); |
799 | 799 | $this->addNoScript(); |
@@ -814,7 +814,7 @@ discard block |
||
814 | 814 | * |
815 | 815 | * @deprecated 1.0.0 Use addLink instead |
816 | 816 | */ |
817 | - function add_link($name, $url=false, $submenu=false) |
|
817 | + function add_link($name, $url = false, $submenu = false) |
|
818 | 818 | { |
819 | 819 | $this->addLink($name, $url, $submenu); |
820 | 820 | } |
@@ -826,7 +826,7 @@ discard block |
||
826 | 826 | * @param false|string $url The URL to link to |
827 | 827 | * @param false|array $subment Any submenu items for the dropdown |
828 | 828 | */ |
829 | - public function addLink($name, $url=false, $submenu=false) |
|
829 | + public function addLink($name, $url = false, $submenu = false) |
|
830 | 830 | { |
831 | 831 | if(is_array($submenu)) |
832 | 832 | { |
@@ -5,7 +5,7 @@ discard block |
||
5 | 5 | { |
6 | 6 | public $server; |
7 | 7 | |
8 | - function __construct($array=false, $server=false) |
|
8 | + function __construct($array = false, $server = false) |
|
9 | 9 | { |
10 | 10 | parent::__construct($array); |
11 | 11 | $this->server = $server; |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | public function jsonSerialize() |
15 | 15 | { |
16 | 16 | $ret = array(); |
17 | - foreach ($this as $key => $value) |
|
17 | + foreach($this as $key => $value) |
|
18 | 18 | { |
19 | 19 | if($key === 'server' || $key === 'count') continue; |
20 | 20 | if(is_numeric($key)) continue; |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | $this->ds = ldap_connect($this->connect); |
77 | 77 | } |
78 | 78 | |
79 | - private function getConnectString($name, $proto=false) |
|
79 | + private function getConnectString($name, $proto = false) |
|
80 | 80 | { |
81 | 81 | if(strstr($name, ':') !== false) |
82 | 82 | { |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | return $name; |
90 | 90 | } |
91 | 91 | |
92 | - function connect($name, $proto=false) |
|
92 | + function connect($name, $proto = false) |
|
93 | 93 | { |
94 | 94 | $connectStr = $this->getConnectString($name, $proto); |
95 | 95 | if($this->ds !== null) |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | $this->connect = false; |
118 | 118 | } |
119 | 119 | |
120 | - function bind($cn=null, $password=null) |
|
120 | + function bind($cn = null, $password = null) |
|
121 | 121 | { |
122 | 122 | $res = false; |
123 | 123 | if($this->ds === null) |
@@ -214,7 +214,7 @@ discard block |
||
214 | 214 | return $filter->to_ldap_string(); |
215 | 215 | } |
216 | 216 | |
217 | - function read($baseDN, $filter=false, $single=false, $attributes=false) |
|
217 | + function read($baseDN, $filter = false, $single = false, $attributes = false) |
|
218 | 218 | { |
219 | 219 | $filterStr = $this->filterToString($filter); |
220 | 220 | if($this->ds === null) |
@@ -261,7 +261,7 @@ discard block |
||
261 | 261 | return $res; |
262 | 262 | } |
263 | 263 | |
264 | - function count($baseDN, $filter=false) |
|
264 | + function count($baseDN, $filter = false) |
|
265 | 265 | { |
266 | 266 | $filterStr = $this->filterToString($filter); |
267 | 267 | if($this->ds === null) |
@@ -157,7 +157,7 @@ discard block |
||
157 | 157 | $len = $pos - $offset; |
158 | 158 | $name = substr($sessionData, $offset, $len); |
159 | 159 | if($name === false) break; |
160 | - $offset += $len+1; |
|
160 | + $offset += $len + 1; |
|
161 | 161 | $data = @unserialize(substr($sessionData, $offset)); |
162 | 162 | $res[$name] = $data; |
163 | 163 | $offset += strlen(serialize($data)); |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | else |
186 | 186 | { |
187 | 187 | $tmp = FlipSession::unserializePhpSession($sessionData); |
188 | - $tmp['sid' ] = $sessionId; |
|
188 | + $tmp['sid'] = $sessionId; |
|
189 | 189 | array_push($res, $tmp); |
190 | 190 | } |
191 | 191 | } |