@@ -312,7 +312,7 @@ discard block |
||
| 312 | 312 | * @param string $appLang the application language, only if type = "language" |
| 313 | 313 | * @return string|null the full file path |
| 314 | 314 | */ |
| 315 | - protected static function getDefaultFilePathForFunctionLanguage($file, $type, $appLang = null){ |
|
| 315 | + protected static function getDefaultFilePathForFunctionLanguage($file, $type, $appLang = null) { |
|
| 316 | 316 | $searchDir = null; |
| 317 | 317 | if ($type == 'function') { |
| 318 | 318 | $searchDir = array(FUNCTIONS_PATH, CORE_FUNCTIONS_PATH); |
@@ -338,7 +338,7 @@ discard block |
||
| 338 | 338 | * @param string|null $module the module if is not null will return it |
| 339 | 339 | * @return string|null |
| 340 | 340 | */ |
| 341 | - protected static function getModuleFromSuperController($module){ |
|
| 341 | + protected static function getModuleFromSuperController($module) { |
|
| 342 | 342 | $obj = & get_instance(); |
| 343 | 343 | if (!$module && !empty($obj->moduleName)) { |
| 344 | 344 | $module = $obj->moduleName; |
@@ -315,7 +315,7 @@ |
||
| 315 | 315 | protected static function getDefaultFilePathForFunctionLanguage($file, $type, $appLang = null){ |
| 316 | 316 | $searchDir = null; |
| 317 | 317 | if ($type == 'function') { |
| 318 | - $searchDir = array(FUNCTIONS_PATH, CORE_FUNCTIONS_PATH); |
|
| 318 | + $searchDir = array(FUNCTIONS_PATH, CORE_FUNCTIONS_PATH); |
|
| 319 | 319 | } |
| 320 | 320 | else if ($type == 'language') { |
| 321 | 321 | $searchDir = array(APP_LANG_PATH, CORE_LANG_PATH); |
@@ -316,8 +316,7 @@ |
||
| 316 | 316 | $searchDir = null; |
| 317 | 317 | if ($type == 'function') { |
| 318 | 318 | $searchDir = array(FUNCTIONS_PATH, CORE_FUNCTIONS_PATH); |
| 319 | - } |
|
| 320 | - else if ($type == 'language') { |
|
| 319 | + } else if ($type == 'language') { |
|
| 321 | 320 | $searchDir = array(APP_LANG_PATH, CORE_LANG_PATH); |
| 322 | 321 | $file = $appLang . DS . $file; |
| 323 | 322 | } |
@@ -355,13 +355,13 @@ discard block |
||
| 355 | 355 | public function setMessage() { |
| 356 | 356 | $numArgs = func_num_args(); |
| 357 | 357 | if ($numArgs == 2) { |
| 358 | - foreach ($this->post(null) as $key => $val) { |
|
| 358 | + foreach ($this->post(null) as $key => $val) { |
|
| 359 | 359 | $this->_errorMsgOverrides[$key][func_get_arg(0)] = func_get_arg(1); |
| 360 | 360 | } |
| 361 | 361 | return true; |
| 362 | 362 | } else if ($numArgs == 3) { |
| 363 | 363 | $this->_errorMsgOverrides[func_get_arg(1)][func_get_arg(0)] = func_get_arg(2); |
| 364 | - return true; |
|
| 364 | + return true; |
|
| 365 | 365 | } |
| 366 | 366 | return false; |
| 367 | 367 | } |
@@ -468,7 +468,7 @@ discard block |
||
| 468 | 468 | if (!empty($regexRule[0])) { |
| 469 | 469 | $ruleSets[] = $regexRule[0]; |
| 470 | 470 | } |
| 471 | - $ruleStringRegex = explode('|', $ruleStringTemp); |
|
| 471 | + $ruleStringRegex = explode('|', $ruleStringTemp); |
|
| 472 | 472 | foreach ($ruleStringRegex as $rule) { |
| 473 | 473 | $rule = trim($rule); |
| 474 | 474 | if ($rule) { |
@@ -277,7 +277,7 @@ |
||
| 277 | 277 | * Set the file array data generally in constructor this is already set using $_FILES |
| 278 | 278 | * @param array $fileArray the new value |
| 279 | 279 | */ |
| 280 | - public function setFileArray($fileArray){ |
|
| 280 | + public function setFileArray($fileArray) { |
|
| 281 | 281 | $this->file_array = $fileArray; |
| 282 | 282 | } |
| 283 | 283 | |
@@ -160,14 +160,14 @@ |
||
| 160 | 160 | } |
| 161 | 161 | |
| 162 | 162 | /** |
| 163 | - * Return the server port using variable |
|
| 164 | - * |
|
| 165 | - * @return string |
|
| 166 | - */ |
|
| 163 | + * Return the server port using variable |
|
| 164 | + * |
|
| 165 | + * @return string |
|
| 166 | + */ |
|
| 167 | 167 | protected static function getServerPort() { |
| 168 | 168 | $serverPort = 80; |
| 169 | 169 | if (isset($_SERVER['SERVER_PORT'])) { |
| 170 | - $serverPort = $_SERVER['SERVER_PORT']; |
|
| 170 | + $serverPort = $_SERVER['SERVER_PORT']; |
|
| 171 | 171 | } |
| 172 | 172 | $port = ''; |
| 173 | 173 | if ((is_https() && $serverPort != 443) || (!is_https() && $serverPort != 80)) { |
@@ -196,13 +196,13 @@ |
||
| 196 | 196 | return $session; |
| 197 | 197 | } |
| 198 | 198 | |
| 199 | - /** |
|
| 200 | - * Get the value from $_GET, $_POST, $_SERVER etc. for given key. if the key is empty will return the all values |
|
| 201 | - * @param string $type the type can be "post", "get", etc. |
|
| 202 | - * @param string $key the item key to be fetched |
|
| 203 | - * @param boolean $xss if need apply some XSS rule on the value |
|
| 204 | - * @return array|mixed the item value if the key exists or all array if the key is null |
|
| 205 | - */ |
|
| 199 | + /** |
|
| 200 | + * Get the value from $_GET, $_POST, $_SERVER etc. for given key. if the key is empty will return the all values |
|
| 201 | + * @param string $type the type can be "post", "get", etc. |
|
| 202 | + * @param string $key the item key to be fetched |
|
| 203 | + * @param boolean $xss if need apply some XSS rule on the value |
|
| 204 | + * @return array|mixed the item value if the key exists or all array if the key is null |
|
| 205 | + */ |
|
| 206 | 206 | protected function getVars($type, $key = null, $xss = true) { |
| 207 | 207 | $data = null; |
| 208 | 208 | if ($key === null) { |
@@ -44,7 +44,7 @@ |
||
| 44 | 44 | self::$logger = $logger[0]; |
| 45 | 45 | } |
| 46 | 46 | if ($setLoggerName) { |
| 47 | - self::$logger->setLogger('Class::' . get_called_class()); |
|
| 47 | + self::$logger->setLogger('Class::' . get_called_class()); |
|
| 48 | 48 | } |
| 49 | 49 | return self::$logger; |
| 50 | 50 | } |