@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | </div> |
58 | 58 | </div> |
59 | 59 | <br /> |
60 | - <?php if ( empty($ip_list)) : ?> |
|
60 | + <?php if (empty($ip_list)) : ?> |
|
61 | 61 | <div id="so-table-container" class="so-datatables"> |
62 | 62 | <table id="so-datalog" class="cell-border compact stripe responsive" cellspacing="0" width="100%"> |
63 | 63 | <tbody> |
@@ -92,8 +92,8 @@ discard block |
||
92 | 92 | </tr> |
93 | 93 | </thead> |
94 | 94 | <tbody> |
95 | - <?php if (! empty($ip_list)) : ?> |
|
96 | - <?php foreach($ip_list as $i => $ipInfo) : ?> |
|
95 | + <?php if (!empty($ip_list)) : ?> |
|
96 | + <?php foreach ($ip_list as $i => $ipInfo) : ?> |
|
97 | 97 | <tr> |
98 | 98 | <td><?php echo $i + 1; ?></td> |
99 | 99 | <td><?php echo $ipInfo['url']; ?></td> |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | </div> |
116 | 116 | </div> |
117 | 117 | |
118 | -<?php if (! empty($ip_list)) : ?> |
|
118 | +<?php if (!empty($ip_list)) : ?> |
|
119 | 119 | |
120 | 120 | <script> |
121 | 121 |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | </div> |
112 | 112 | </div> |
113 | 113 | <br /> |
114 | - <?php if ( empty($xss_protected_list)) : ?> |
|
114 | + <?php if (empty($xss_protected_list)) : ?> |
|
115 | 115 | <div id="so-table-container" class="so-datatables"> |
116 | 116 | <table id="so-datalog" class="cell-border compact stripe responsive" cellspacing="0" width="100%"> |
117 | 117 | <tbody> |
@@ -143,8 +143,8 @@ discard block |
||
143 | 143 | </tr> |
144 | 144 | </thead> |
145 | 145 | <tbody> |
146 | - <?php if (! empty($xss_protected_list)) : ?> |
|
147 | - <?php foreach($xss_protected_list as $i => $info) : ?> |
|
146 | + <?php if (!empty($xss_protected_list)) : ?> |
|
147 | + <?php foreach ($xss_protected_list as $i => $info) : ?> |
|
148 | 148 | <tr> |
149 | 149 | <td><?php echo $info['type']; ?></td> |
150 | 150 | <td><?php echo $info['variable']; ?></td> |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | </div> |
36 | 36 | <div class="board-field right"> |
37 | 37 | <div class="heading"><?php _e('panel', 'table_heading_period', 'Period'); ?></div> |
38 | - <div class="nums"><?php echo number_format($session_limit_period ); ?></div> |
|
38 | + <div class="nums"><?php echo number_format($session_limit_period); ?></div> |
|
39 | 39 | <div class="note"><?php _e('panel', 'table_note_period', 'Keep-alive period. (minutes)'); ?></div> |
40 | 40 | </div> |
41 | 41 | </div> |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | </div> |
46 | 46 | <div class="board-field right"> |
47 | 47 | <div class="heading"><?php _e('panel', 'table_heading_online', 'Online'); ?></div> |
48 | - <div class="nums"><?php echo number_format($online_count ); ?></div> |
|
48 | + <div class="nums"><?php echo number_format($online_count); ?></div> |
|
49 | 49 | <div class="note"><?php _e('panel', 'table_note_online', 'Online session amount.'); ?></div> |
50 | 50 | </div> |
51 | 51 | </div> |
@@ -80,19 +80,19 @@ discard block |
||
80 | 80 | <tbody> |
81 | 81 | |
82 | 82 | <?php $i = 1; ?> |
83 | - <?php foreach($session_list as $key => $sessionInfo) : ?> |
|
83 | + <?php foreach ($session_list as $key => $sessionInfo) : ?> |
|
84 | 84 | <?php |
85 | 85 | |
86 | 86 | $remainsTime = $expires - (time() - $sessionInfo['time']); |
87 | 87 | |
88 | - if ($remainsTime < 1 ) { |
|
88 | + if ($remainsTime < 1) { |
|
89 | 89 | $remainsTime = 0; |
90 | 90 | } |
91 | 91 | |
92 | - if ($i < $session_limit_count ) { |
|
92 | + if ($i < $session_limit_count) { |
|
93 | 93 | $satusName = __('panel', 'table_text_allowable', 'Allowable'); |
94 | 94 | |
95 | - if ($remainsTime < 1 ) { |
|
95 | + if ($remainsTime < 1) { |
|
96 | 96 | $satusName = __('panel', 'table_text_expired', 'Expired'); |
97 | 97 | } |
98 | 98 | } else { |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | <div class="card-body"> |
116 | 116 | <form action="<?php echo $_SERVER['REQUEST_URI'] ?>" method="post" autocomplete="off"> |
117 | 117 | <div class="main-content"> |
118 | - <?php if (! empty($error)) : ?> |
|
118 | + <?php if (!empty($error)) : ?> |
|
119 | 119 | <div class="error-notice"> |
120 | 120 | <?php echo $error; ?> |
121 | 121 | </div> |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | <div class="input-box"> |
127 | 127 | <input type="password" name="s_pass" placeholder="Password" class="form-input" /> |
128 | 128 | </div> |
129 | - <?php if (! empty($this->captcha)) : ?> |
|
129 | + <?php if (!empty($this->captcha)) : ?> |
|
130 | 130 | <div class="input-box"> |
131 | 131 | <?php foreach ($this->captcha as $captcha) : ?> |
132 | 132 | <?php echo $captcha->form(); ?> |
@@ -37,9 +37,9 @@ |
||
37 | 37 | <?php _e('core', 'deny_message', 'The IP address you are using has been blocked.') ?> |
38 | 38 | </div> |
39 | 39 | </div> |
40 | - <?php if (! empty($dialoguserinfo)) : ?> |
|
40 | + <?php if (!empty($dialoguserinfo)) : ?> |
|
41 | 41 | <div class="status-user-info"> |
42 | - <?php foreach($dialoguserinfo as $key => $userinfo) : ?> |
|
42 | + <?php foreach ($dialoguserinfo as $key => $userinfo) : ?> |
|
43 | 43 | <div class="row"> |
44 | 44 | <strong><?php echo $key; ?></strong> <span><?php echo $userinfo; ?></span> |
45 | 45 | </div> |
@@ -46,9 +46,9 @@ |
||
46 | 46 | <p><input type="submit" value="<?php _e('core', 'stop_submit', 'Submit') ?>" /></p> |
47 | 47 | </form> |
48 | 48 | </div> |
49 | - <?php if (! empty($dialoguserinfo)) : ?> |
|
49 | + <?php if (!empty($dialoguserinfo)) : ?> |
|
50 | 50 | <div class="status-user-info"> |
51 | - <?php foreach($dialoguserinfo as $key => $userinfo) : ?> |
|
51 | + <?php foreach ($dialoguserinfo as $key => $userinfo) : ?> |
|
52 | 52 | <div class="row"> |
53 | 53 | <strong><?php echo $key; ?></strong> <span><?php echo $userinfo; ?></span> |
54 | 54 | </div> |
@@ -201,13 +201,12 @@ discard block |
||
201 | 201 | $imgHeight = $this->properties['img_height']; |
202 | 202 | |
203 | 203 | // Determine angle and position. |
204 | - $length = strlen($this->word); |
|
204 | + $length = strlen($this->word); |
|
205 | 205 | $angle = ($length >= 6) ?mt_rand(-($length - 6), ($length - 6)) : 0; |
206 | 206 | $xAxis = mt_rand(6, (360 / $length) - 16); |
207 | 207 | |
208 | 208 | $yAxis = ($angle >= 0) ? |
209 | - mt_rand($imgHeight, $imgWidth) : |
|
210 | - mt_rand(6, $imgHeight); |
|
209 | + mt_rand($imgHeight, $imgWidth) : mt_rand(6, $imgHeight); |
|
211 | 210 | |
212 | 211 | // Create image. |
213 | 212 | if (function_exists('imagecreatetruecolor')) { |
@@ -258,7 +257,7 @@ discard block |
||
258 | 257 | $y = 0; |
259 | 258 | |
260 | 259 | for ($i = 0; $i < $length; $i++) { |
261 | - $y = mt_rand(0 , $imgHeight / 2); |
|
260 | + $y = mt_rand(0, $imgHeight / 2); |
|
262 | 261 | imagestring($im, 5, $x, $y, $this->word[$i], $colors['text']); |
263 | 262 | $x += ($this->properties['font_spacing'] * 2); |
264 | 263 | } |
@@ -267,7 +266,7 @@ discard block |
||
267 | 266 | imagerectangle($im, 0, 0, $imgWidth - 1, $imgHeight - 1, $colors['border']); |
268 | 267 | |
269 | 268 | // Generate image in base64 string. |
270 | - ob_start (); |
|
269 | + ob_start(); |
|
271 | 270 | |
272 | 271 | if (function_exists('imagejpeg')) { |
273 | 272 | $this->imageType = 'jpeg'; |
@@ -97,7 +97,7 @@ discard block |
||
97 | 97 | |
98 | 98 | $keys = $this->redis->keys($this->getNamespace($type) . ':*'); |
99 | 99 | |
100 | - foreach($keys as $key) { |
|
100 | + foreach ($keys as $key) { |
|
101 | 101 | $content = $this->redis->get($key); |
102 | 102 | $content = json_decode($content, true); |
103 | 103 | |
@@ -228,7 +228,7 @@ discard block |
||
228 | 228 | $keys = $this->redis->keys($this->getNamespace($type) . ':*'); |
229 | 229 | |
230 | 230 | if (!empty($keys)) { |
231 | - foreach($keys as $key) { |
|
231 | + foreach ($keys as $key) { |
|
232 | 232 | $this->redis->del($key); |
233 | 233 | } |
234 | 234 | } |
@@ -45,7 +45,7 @@ |
||
45 | 45 | public function isDenied(): bool |
46 | 46 | { |
47 | 47 | if (!empty($this->deniedList)) { |
48 | - if (preg_match('/(' . implode('|', $this->deniedList). ')/i', $this->rdns)) { |
|
48 | + if (preg_match('/(' . implode('|', $this->deniedList) . ')/i', $this->rdns)) { |
|
49 | 49 | return true; |
50 | 50 | } |
51 | 51 | } |