@@ -26,7 +26,7 @@ |
||
26 | 26 | |
27 | 27 | $fs = new Filesystem(); |
28 | 28 | if (!$fs->isAbsolutePath($config)) { |
29 | - $config = __DIR__.'/config/'.$config; |
|
29 | + $config = __DIR__ . '/config/' . $config; |
|
30 | 30 | } |
31 | 31 | |
32 | 32 | if (!file_exists($config)) { |
@@ -118,7 +118,7 @@ |
||
118 | 118 | } |
119 | 119 | } |
120 | 120 | } |
121 | -EOF |
|
121 | +eof |
|
122 | 122 | ; |
123 | 123 | |
124 | 124 | return json_decode($json, true); |
@@ -24,7 +24,7 @@ |
||
24 | 24 | ->setDescription('Loads bundles into persistences') |
25 | 25 | ->setHelp(<<<'EOT' |
26 | 26 | The <info>scan:bundles</info> command loads bundle table. |
27 | -EOT |
|
27 | +eot |
|
28 | 28 | ) |
29 | 29 | ->setDefinition([ |
30 | 30 | new InputArgument('create', InputArgument::OPTIONAL, 'Create schema'), |
@@ -132,7 +132,7 @@ |
||
132 | 132 | if ($gid < 1 || $uid < 1) { |
133 | 133 | throw new \InvalidArgumentException($this->__('Invalid Group ID or User ID.')); |
134 | 134 | } |
135 | - if (!$this->hasPermission('ZikulaGroupsModule::', $gid.'::', ACCESS_EDIT)) { |
|
135 | + if (!$this->hasPermission('ZikulaGroupsModule::', $gid . '::', ACCESS_EDIT)) { |
|
136 | 136 | throw new AccessDeniedException(); |
137 | 137 | } |
138 | 138 | $group = $this->get('zikula_groups_module.group_repository')->find($gid); |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | case 'lang': |
140 | 140 | $addcurrentlang2url = $systemVars['languageurl']; |
141 | 141 | if ($addcurrentlang2url == 0) { |
142 | - $pager['args'][$k] = $v; |
|
142 | + $pager['args'][$k] = $v; |
|
143 | 143 | } |
144 | 144 | break; |
145 | 145 | default: |
@@ -161,19 +161,19 @@ discard block |
||
161 | 161 | } |
162 | 162 | } elseif (strlen($vv)) { |
163 | 163 | $tkey = $k . '[' . $kk . ']'; |
164 | - $pager['args'][$tkey] = $vv; |
|
164 | + $pager['args'][$tkey] = $vv; |
|
165 | 165 | } |
166 | 166 | } |
167 | 167 | } else { |
168 | 168 | if (strlen($v)) { |
169 | - $pager['args'][$k] = $v; |
|
169 | + $pager['args'][$k] = $v; |
|
170 | 170 | } |
171 | 171 | } |
172 | 172 | } |
173 | 173 | } |
174 | 174 | } |
175 | 175 | |
176 | - $pagerUrl = function ($pager) use ($routeName, $systemVars) { |
|
176 | + $pagerUrl = function($pager) use ($routeName, $systemVars) { |
|
177 | 177 | if ($routeName) { |
178 | 178 | return $this->container->get('router')->generate($routeName, $pager['args']); |
179 | 179 | } |
@@ -373,7 +373,7 @@ discard block |
||
373 | 373 | // predefined abc |
374 | 374 | if (strtolower($params['skin']) == 'hu') { |
375 | 375 | // Hungarian |
376 | - $pager['names'] = $pager['values'] = ['A', '?', 'B', 'C', 'D', 'E', '?', 'F', 'G', 'H', 'I', '?', 'J', 'K', 'L', 'M', 'N', 'O', '?', '?', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', '?', '?', 'U', 'V', 'W', 'X', 'Y', 'Z']; |
|
376 | + $pager['names'] = $pager['values'] = ['A', '?', 'B', 'C', 'D', 'E', '?', 'F', 'G', 'H', 'I', '?', 'J', 'K', 'L', 'M', 'N', 'O', '?', '?', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', '?', '?', 'U', 'V', 'W', 'X', 'Y', 'Z']; |
|
377 | 377 | //$params['names'] = array('A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U' ,'V','W','X','Y','Z'); |
378 | 378 | //$params['values'] = array('A,?','B','C','D','E,?','F','G','H','I,?','J','K','L','M','N','O,?,?,O','P','Q','R','S','T','U,?,?,U','V','W','X','Y','Z'); |
379 | 379 | } else { |
@@ -387,7 +387,7 @@ discard block |
||
387 | 387 | unset($params['names']); |
388 | 388 | unset($params['values']); |
389 | 389 | unset($params['route']); |
390 | - $pagerUrl = function ($pager) { |
|
390 | + $pagerUrl = function($pager) { |
|
391 | 391 | return $this->container->get('router')->generate($pager['route'], $pager['args']); |
392 | 392 | }; |
393 | 393 | $allVars = array_merge($request->request->all(), $request->query->all(), $request->attributes->get('_route_params', [])); |
@@ -418,38 +418,38 @@ discard block |
||
418 | 418 | } |
419 | 419 | unset($pager['args'][$pager['posvar']]); |
420 | 420 | // begin to fill the output |
421 | - $output = '<ul class="'.$params['class'].'">'."\n"; |
|
421 | + $output = '<ul class="' . $params['class'] . '">' . "\n"; |
|
422 | 422 | $style = ''; |
423 | 423 | if ($params['printempty']) { |
424 | 424 | $active = ''; |
425 | 425 | if (!empty($params['class_numon'])) { |
426 | 426 | if (!isset($allVars[$pager['posvar']])) { |
427 | - $style = ' class="'.$params['class_numon'].'"'; |
|
427 | + $style = ' class="' . $params['class_numon'] . '"'; |
|
428 | 428 | $active = 'class="active"'; |
429 | 429 | } elseif (!empty($params['class_num'])) { |
430 | - $style = ' class="'.$params['class_num'].'"'; |
|
430 | + $style = ' class="' . $params['class_num'] . '"'; |
|
431 | 431 | } else { |
432 | 432 | $style = ''; |
433 | 433 | } |
434 | 434 | } |
435 | 435 | $vars[$pager['posvar']] = ''; |
436 | - $output .= '<li '.$active.'><a '.$style.' href="'.$pagerUrl($pager).'"> -'."\n</a></li>"; |
|
436 | + $output .= '<li ' . $active . '><a ' . $style . ' href="' . $pagerUrl($pager) . '"> -' . "\n</a></li>"; |
|
437 | 437 | } |
438 | 438 | $style = ''; |
439 | 439 | foreach (array_keys($pager['names']) as $i) { |
440 | 440 | $active = ''; |
441 | 441 | if (!empty($params['class_numon'])) { |
442 | 442 | if (isset($allVars[$pager['posvar']]) && $allVars[$pager['posvar']] == $pager['values'][$i]) { |
443 | - $style = ' class="'.$params['class_numon'].'"'; |
|
443 | + $style = ' class="' . $params['class_numon'] . '"'; |
|
444 | 444 | $active = 'class="active"'; |
445 | 445 | } elseif (!empty($params['class_num'])) { |
446 | - $style = ' class="'.$params['class_num'].'"'; |
|
446 | + $style = ' class="' . $params['class_num'] . '"'; |
|
447 | 447 | } else { |
448 | 448 | $style = ''; |
449 | 449 | } |
450 | 450 | } |
451 | 451 | $pager['args'][$pager['posvar']] = $pager['values'][$i]; |
452 | - $output .= '<li '.$active.'><a '.$style.' href="'.$pagerUrl($pager).'">'.$pager['names'][$i]."</a></li>\n"; |
|
452 | + $output .= '<li ' . $active . '><a ' . $style . ' href="' . $pagerUrl($pager) . '">' . $pager['names'][$i] . "</a></li>\n"; |
|
453 | 453 | } |
454 | 454 | $output .= "</ul>\n"; |
455 | 455 |
@@ -59,11 +59,11 @@ |
||
59 | 59 | $availableLanguages = []; |
60 | 60 | foreach ($matches as $match) { |
61 | 61 | list($languageCode, $unusedVar) = explode('-', $match[1]) + ['', '']; |
62 | - $priority = isset($match[2]) ? (float) $match[2] : 1.0; |
|
62 | + $priority = isset($match[2]) ? (float)$match[2] : 1.0; |
|
63 | 63 | $availableLanguages[][$languageCode] = $priority; |
64 | 64 | } |
65 | 65 | |
66 | - $defaultPriority = (float) 0; |
|
66 | + $defaultPriority = (float)0; |
|
67 | 67 | $matchedLanguage = ''; |
68 | 68 | foreach ($availableLanguages as $key => $value) { |
69 | 69 | $languageCode = key($value); |
@@ -182,9 +182,9 @@ discard block |
||
182 | 182 | $ldir = dirname(__FILE__); |
183 | 183 | $p = strpos($ldir, DIRECTORY_SEPARATOR . 'system'); // we are in system/AdminModule |
184 | 184 | $b = substr($ldir, 0, $p); |
185 | - $filePath = $b.'/'.$appDir.'/.htaccess'; |
|
185 | + $filePath = $b . '/' . $appDir . '/.htaccess'; |
|
186 | 186 | } else { |
187 | - $filePath = $appDir.'/.htaccess'; |
|
187 | + $filePath = $appDir . '/.htaccess'; |
|
188 | 188 | } |
189 | 189 | $app_htaccess = file_exists($filePath); |
190 | 190 | } |
@@ -199,7 +199,7 @@ discard block |
||
199 | 199 | return $this->render('@ZikulaAdminModule/AdminInterface/securityAnalyzer.html.twig', [ |
200 | 200 | 'security' => [ |
201 | 201 | 'config_php' => is_writable('config/config.php'), |
202 | - 'magic_quotes_gpc' => (bool) get_magic_quotes_gpc(), // should be off anyway... |
|
202 | + 'magic_quotes_gpc' => (bool)get_magic_quotes_gpc(), // should be off anyway... |
|
203 | 203 | 'app_htaccess' => $app_htaccess, |
204 | 204 | 'updatecheck' => $variableApi->getSystemVar('updatecheck'), |
205 | 205 | 'scactive' => $hasSecurityCenter, |
@@ -26,7 +26,7 @@ |
||
26 | 26 | */ |
27 | 27 | public function load(array $configs, ContainerBuilder $container) |
28 | 28 | { |
29 | - $loader = new YamlFileLoader($container, new FileLocator(realpath(__DIR__.'/../Resources/config'))); |
|
29 | + $loader = new YamlFileLoader($container, new FileLocator(realpath(__DIR__ . '/../Resources/config'))); |
|
30 | 30 | |
31 | 31 | $loader->load('services.yml'); |
32 | 32 | } |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | |
35 | 35 | if ($sessionId != '') { |
36 | 36 | $qb->where('tbl.sesid = :sid') |
37 | - ->setParameter('sid', $sessionId); |
|
37 | + ->setParameter('sid', $sessionId); |
|
38 | 38 | } |
39 | 39 | |
40 | 40 | $query = $qb->getQuery(); |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | $i = 1; |
65 | 65 | foreach ($filters as $w_key => $w_value) { |
66 | 66 | $qb->andWhere($qb->expr()->eq('tbl.' . $w_key, '?' . $i)) |
67 | - ->setParameter($i, $w_value); |
|
67 | + ->setParameter($i, $w_value); |
|
68 | 68 | $i++; |
69 | 69 | } |
70 | 70 | } |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | |
105 | 105 | if ($sessionId != '') { |
106 | 106 | $qb->orWhere('tbl.sesid = :sid') |
107 | - ->setParameter('sid', $sessionId); |
|
107 | + ->setParameter('sid', $sessionId); |
|
108 | 108 | } |
109 | 109 | |
110 | 110 | $query = $qb->getQuery(); |