@@ -121,7 +121,7 @@ |
||
| 121 | 121 | |
| 122 | 122 | $files = array_unique(array_merge($always_update, array_filter( |
| 123 | 123 | explode("\n", shell_exec('git diff --name-only v' . $prev_version . '...HEAD')), |
| 124 | - function ($filename) |
|
| 124 | + function($filename) |
|
| 125 | 125 | { |
| 126 | 126 | return file_exists($filename) && strpos(mime_content_type($filename), 'text/') === 0; |
| 127 | 127 | } |
@@ -448,7 +448,7 @@ |
||
| 448 | 448 | function array_column($input, $column_key, $index_key = null) |
| 449 | 449 | { |
| 450 | 450 | $arr = array_map( |
| 451 | - function ($d) use ($column_key, $index_key) { |
|
| 451 | + function($d) use ($column_key, $index_key) { |
|
| 452 | 452 | if (!isset($d[$column_key])) { |
| 453 | 453 | return; |
| 454 | 454 | } |
@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | 'mysql' => [ |
| 55 | 55 | 'name' => 'MySQL', |
| 56 | 56 | 'version' => '5.6.0', |
| 57 | - 'version_check' => function () { |
|
| 57 | + 'version_check' => function() { |
|
| 58 | 58 | if (!function_exists('mysqli_fetch_row')) { |
| 59 | 59 | return false; |
| 60 | 60 | } |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | 'postgresql' => [ |
| 67 | 67 | 'name' => 'PostgreSQL', |
| 68 | 68 | 'version' => '9.6', |
| 69 | - 'version_check' => function () { |
|
| 69 | + 'version_check' => function() { |
|
| 70 | 70 | if (!function_exists('pg_version')) { |
| 71 | 71 | return false; |
| 72 | 72 | } |
@@ -596,7 +596,7 @@ discard block |
||
| 596 | 596 | $to = explode('/', $lang_dir); |
| 597 | 597 | $relPath = $to; |
| 598 | 598 | |
| 599 | - foreach($from as $depth => $dir) { |
|
| 599 | + foreach ($from as $depth => $dir) { |
|
| 600 | 600 | if ($dir === $to[$depth]) { |
| 601 | 601 | array_shift($relPath); |
| 602 | 602 | } else { |
@@ -1108,7 +1108,7 @@ discard block |
||
| 1108 | 1108 | // PHP currently has a terrible handling with unserialize in which errors are fatal and not catchable. Lets borrow some code from the RFC that intends to fix this |
| 1109 | 1109 | // https://wiki.php.net/rfc/improve_unserialize_error_handling |
| 1110 | 1110 | try { |
| 1111 | - set_error_handler(static function ($severity, $message, $file, $line) { |
|
| 1111 | + set_error_handler(static function($severity, $message, $file, $line) { |
|
| 1112 | 1112 | throw new \ErrorException($message, 0, $severity, $file, $line); |
| 1113 | 1113 | }); |
| 1114 | 1114 | $ser_test = @unserialize(Config::$modSettings['attachmentUploadDir']); |
@@ -1135,7 +1135,7 @@ discard block |
||
| 1135 | 1135 | } |
| 1136 | 1136 | // An array already? |
| 1137 | 1137 | elseif (is_array(Config::$modSettings['attachmentUploadDir'])) { |
| 1138 | - foreach(Config::$modSettings['attachmentUploadDir'] as $dir) { |
|
| 1138 | + foreach (Config::$modSettings['attachmentUploadDir'] as $dir) { |
|
| 1139 | 1139 | if (!empty($dir) && !is_dir($dir)) { |
| 1140 | 1140 | $attdr_problem_found = true; |
| 1141 | 1141 | } |
@@ -1144,7 +1144,7 @@ discard block |
||
| 1144 | 1144 | // Serialized? |
| 1145 | 1145 | elseif ($ser_test !== false) { |
| 1146 | 1146 | if (is_array($ser_test)) { |
| 1147 | - foreach($ser_test as $dir) { |
|
| 1147 | + foreach ($ser_test as $dir) { |
|
| 1148 | 1148 | if (!empty($dir) && !is_dir($dir)) { |
| 1149 | 1149 | $attdr_problem_found = true; |
| 1150 | 1150 | } |
@@ -1158,7 +1158,7 @@ discard block |
||
| 1158 | 1158 | // Json? Note the test returns null if encoding was unsuccessful |
| 1159 | 1159 | elseif ($json_test !== null) { |
| 1160 | 1160 | if (is_array($json_test)) { |
| 1161 | - foreach($json_test as $dir) { |
|
| 1161 | + foreach ($json_test as $dir) { |
|
| 1162 | 1162 | if (!is_dir($dir)) { |
| 1163 | 1163 | $attdr_problem_found = true; |
| 1164 | 1164 | } |
@@ -2231,7 +2231,7 @@ discard block |
||
| 2231 | 2231 | // will return 4437 (E_ERROR | E_CORE_ERROR | E_COMPILE_ERROR | E_USER_ERROR | E_RECOVERABLE_ERROR | E_PARSE) |
| 2232 | 2232 | // as it does so. |
| 2233 | 2233 | set_error_handler( |
| 2234 | - function ($errno, $errstr, $errfile, $errline) use ($support_js) { |
|
| 2234 | + function($errno, $errstr, $errfile, $errline) use ($support_js) { |
|
| 2235 | 2235 | if ($support_js) { |
| 2236 | 2236 | return true; |
| 2237 | 2237 | } |
@@ -3254,101 +3254,101 @@ discard block |
||
| 3254 | 3254 | ]; |
| 3255 | 3255 | |
| 3256 | 3256 | // Default to ISO-8859-1 unless we detected another supported charset |
| 3257 | - $upcontext['charset_detected'] = (isset($lang_charsets[Config::$language], $charsets[strtr(strtolower($upcontext['charset_detected']),['utf' => 'UTF', 'iso' => 'ISO'])])) ? $lang_charsets[Config::$language] : 'ISO-8859-1'; |
|
| 3257 | + $upcontext['charset_detected'] = (isset($lang_charsets[Config::$language], $charsets[strtr(strtolower($upcontext['charset_detected']), ['utf' => 'UTF', 'iso' => 'ISO'])])) ? $lang_charsets[Config::$language] : 'ISO-8859-1'; |
|
| 3258 | 3258 | |
| 3259 | 3259 | $upcontext['charset_list'] = array_keys($charsets); |
| 3260 | 3260 | |
| 3261 | 3261 | // Translation table for the character sets not native for MySQL. |
| 3262 | 3262 | $translation_tables = [ |
| 3263 | 3263 | 'windows-1255' => [ |
| 3264 | - '0x81' => '\'\'', '0x8A' => '\'\'', '0x8C' => '\'\'', |
|
| 3265 | - '0x8D' => '\'\'', '0x8E' => '\'\'', '0x8F' => '\'\'', |
|
| 3266 | - '0x90' => '\'\'', '0x9A' => '\'\'', '0x9C' => '\'\'', |
|
| 3267 | - '0x9D' => '\'\'', '0x9E' => '\'\'', '0x9F' => '\'\'', |
|
| 3268 | - '0xCA' => '\'\'', '0xD9' => '\'\'', '0xDA' => '\'\'', |
|
| 3269 | - '0xDB' => '\'\'', '0xDC' => '\'\'', '0xDD' => '\'\'', |
|
| 3270 | - '0xDE' => '\'\'', '0xDF' => '\'\'', '0xFB' => '0xD792', |
|
| 3271 | - '0xFC' => '0xE282AC', '0xFF' => '0xD6B2', '0xC2' => '0xFF', |
|
| 3272 | - '0x80' => '0xFC', '0xE2' => '0xFB', '0xA0' => '0xC2A0', |
|
| 3273 | - '0xA1' => '0xC2A1', '0xA2' => '0xC2A2', '0xA3' => '0xC2A3', |
|
| 3274 | - '0xA5' => '0xC2A5', '0xA6' => '0xC2A6', '0xA7' => '0xC2A7', |
|
| 3275 | - '0xA8' => '0xC2A8', '0xA9' => '0xC2A9', '0xAB' => '0xC2AB', |
|
| 3276 | - '0xAC' => '0xC2AC', '0xAD' => '0xC2AD', '0xAE' => '0xC2AE', |
|
| 3277 | - '0xAF' => '0xC2AF', '0xB0' => '0xC2B0', '0xB1' => '0xC2B1', |
|
| 3278 | - '0xB2' => '0xC2B2', '0xB3' => '0xC2B3', '0xB4' => '0xC2B4', |
|
| 3279 | - '0xB5' => '0xC2B5', '0xB6' => '0xC2B6', '0xB7' => '0xC2B7', |
|
| 3280 | - '0xB8' => '0xC2B8', '0xB9' => '0xC2B9', '0xBB' => '0xC2BB', |
|
| 3281 | - '0xBC' => '0xC2BC', '0xBD' => '0xC2BD', '0xBE' => '0xC2BE', |
|
| 3282 | - '0xBF' => '0xC2BF', '0xD7' => '0xD7B3', '0xD1' => '0xD781', |
|
| 3283 | - '0xD4' => '0xD7B0', '0xD5' => '0xD7B1', '0xD6' => '0xD7B2', |
|
| 3284 | - '0xE0' => '0xD790', '0xEA' => '0xD79A', '0xEC' => '0xD79C', |
|
| 3285 | - '0xED' => '0xD79D', '0xEE' => '0xD79E', '0xEF' => '0xD79F', |
|
| 3286 | - '0xF0' => '0xD7A0', '0xF1' => '0xD7A1', '0xF2' => '0xD7A2', |
|
| 3287 | - '0xF3' => '0xD7A3', '0xF5' => '0xD7A5', '0xF6' => '0xD7A6', |
|
| 3288 | - '0xF7' => '0xD7A7', '0xF8' => '0xD7A8', '0xF9' => '0xD7A9', |
|
| 3289 | - '0x82' => '0xE2809A', '0x84' => '0xE2809E', '0x85' => '0xE280A6', |
|
| 3290 | - '0x86' => '0xE280A0', '0x87' => '0xE280A1', '0x89' => '0xE280B0', |
|
| 3291 | - '0x8B' => '0xE280B9', '0x93' => '0xE2809C', '0x94' => '0xE2809D', |
|
| 3292 | - '0x95' => '0xE280A2', '0x97' => '0xE28094', '0x99' => '0xE284A2', |
|
| 3293 | - '0xC0' => '0xD6B0', '0xC1' => '0xD6B1', '0xC3' => '0xD6B3', |
|
| 3294 | - '0xC4' => '0xD6B4', '0xC5' => '0xD6B5', '0xC6' => '0xD6B6', |
|
| 3295 | - '0xC7' => '0xD6B7', '0xC8' => '0xD6B8', '0xC9' => '0xD6B9', |
|
| 3296 | - '0xCB' => '0xD6BB', '0xCC' => '0xD6BC', '0xCD' => '0xD6BD', |
|
| 3297 | - '0xCE' => '0xD6BE', '0xCF' => '0xD6BF', '0xD0' => '0xD780', |
|
| 3298 | - '0xD2' => '0xD782', '0xE3' => '0xD793', '0xE4' => '0xD794', |
|
| 3299 | - '0xE5' => '0xD795', '0xE7' => '0xD797', '0xE9' => '0xD799', |
|
| 3300 | - '0xFD' => '0xE2808E', '0xFE' => '0xE2808F', '0x92' => '0xE28099', |
|
| 3301 | - '0x83' => '0xC692', '0xD3' => '0xD783', '0x88' => '0xCB86', |
|
| 3302 | - '0x98' => '0xCB9C', '0x91' => '0xE28098', '0x96' => '0xE28093', |
|
| 3303 | - '0xBA' => '0xC3B7', '0x9B' => '0xE280BA', '0xAA' => '0xC397', |
|
| 3304 | - '0xA4' => '0xE282AA', '0xE1' => '0xD791', '0xE6' => '0xD796', |
|
| 3305 | - '0xE8' => '0xD798', '0xEB' => '0xD79B', '0xF4' => '0xD7A4', |
|
| 3264 | + '0x81' => '\'\'', '0x8A' => '\'\'', '0x8C' => '\'\'', |
|
| 3265 | + '0x8D' => '\'\'', '0x8E' => '\'\'', '0x8F' => '\'\'', |
|
| 3266 | + '0x90' => '\'\'', '0x9A' => '\'\'', '0x9C' => '\'\'', |
|
| 3267 | + '0x9D' => '\'\'', '0x9E' => '\'\'', '0x9F' => '\'\'', |
|
| 3268 | + '0xCA' => '\'\'', '0xD9' => '\'\'', '0xDA' => '\'\'', |
|
| 3269 | + '0xDB' => '\'\'', '0xDC' => '\'\'', '0xDD' => '\'\'', |
|
| 3270 | + '0xDE' => '\'\'', '0xDF' => '\'\'', '0xFB' => '0xD792', |
|
| 3271 | + '0xFC' => '0xE282AC', '0xFF' => '0xD6B2', '0xC2' => '0xFF', |
|
| 3272 | + '0x80' => '0xFC', '0xE2' => '0xFB', '0xA0' => '0xC2A0', |
|
| 3273 | + '0xA1' => '0xC2A1', '0xA2' => '0xC2A2', '0xA3' => '0xC2A3', |
|
| 3274 | + '0xA5' => '0xC2A5', '0xA6' => '0xC2A6', '0xA7' => '0xC2A7', |
|
| 3275 | + '0xA8' => '0xC2A8', '0xA9' => '0xC2A9', '0xAB' => '0xC2AB', |
|
| 3276 | + '0xAC' => '0xC2AC', '0xAD' => '0xC2AD', '0xAE' => '0xC2AE', |
|
| 3277 | + '0xAF' => '0xC2AF', '0xB0' => '0xC2B0', '0xB1' => '0xC2B1', |
|
| 3278 | + '0xB2' => '0xC2B2', '0xB3' => '0xC2B3', '0xB4' => '0xC2B4', |
|
| 3279 | + '0xB5' => '0xC2B5', '0xB6' => '0xC2B6', '0xB7' => '0xC2B7', |
|
| 3280 | + '0xB8' => '0xC2B8', '0xB9' => '0xC2B9', '0xBB' => '0xC2BB', |
|
| 3281 | + '0xBC' => '0xC2BC', '0xBD' => '0xC2BD', '0xBE' => '0xC2BE', |
|
| 3282 | + '0xBF' => '0xC2BF', '0xD7' => '0xD7B3', '0xD1' => '0xD781', |
|
| 3283 | + '0xD4' => '0xD7B0', '0xD5' => '0xD7B1', '0xD6' => '0xD7B2', |
|
| 3284 | + '0xE0' => '0xD790', '0xEA' => '0xD79A', '0xEC' => '0xD79C', |
|
| 3285 | + '0xED' => '0xD79D', '0xEE' => '0xD79E', '0xEF' => '0xD79F', |
|
| 3286 | + '0xF0' => '0xD7A0', '0xF1' => '0xD7A1', '0xF2' => '0xD7A2', |
|
| 3287 | + '0xF3' => '0xD7A3', '0xF5' => '0xD7A5', '0xF6' => '0xD7A6', |
|
| 3288 | + '0xF7' => '0xD7A7', '0xF8' => '0xD7A8', '0xF9' => '0xD7A9', |
|
| 3289 | + '0x82' => '0xE2809A', '0x84' => '0xE2809E', '0x85' => '0xE280A6', |
|
| 3290 | + '0x86' => '0xE280A0', '0x87' => '0xE280A1', '0x89' => '0xE280B0', |
|
| 3291 | + '0x8B' => '0xE280B9', '0x93' => '0xE2809C', '0x94' => '0xE2809D', |
|
| 3292 | + '0x95' => '0xE280A2', '0x97' => '0xE28094', '0x99' => '0xE284A2', |
|
| 3293 | + '0xC0' => '0xD6B0', '0xC1' => '0xD6B1', '0xC3' => '0xD6B3', |
|
| 3294 | + '0xC4' => '0xD6B4', '0xC5' => '0xD6B5', '0xC6' => '0xD6B6', |
|
| 3295 | + '0xC7' => '0xD6B7', '0xC8' => '0xD6B8', '0xC9' => '0xD6B9', |
|
| 3296 | + '0xCB' => '0xD6BB', '0xCC' => '0xD6BC', '0xCD' => '0xD6BD', |
|
| 3297 | + '0xCE' => '0xD6BE', '0xCF' => '0xD6BF', '0xD0' => '0xD780', |
|
| 3298 | + '0xD2' => '0xD782', '0xE3' => '0xD793', '0xE4' => '0xD794', |
|
| 3299 | + '0xE5' => '0xD795', '0xE7' => '0xD797', '0xE9' => '0xD799', |
|
| 3300 | + '0xFD' => '0xE2808E', '0xFE' => '0xE2808F', '0x92' => '0xE28099', |
|
| 3301 | + '0x83' => '0xC692', '0xD3' => '0xD783', '0x88' => '0xCB86', |
|
| 3302 | + '0x98' => '0xCB9C', '0x91' => '0xE28098', '0x96' => '0xE28093', |
|
| 3303 | + '0xBA' => '0xC3B7', '0x9B' => '0xE280BA', '0xAA' => '0xC397', |
|
| 3304 | + '0xA4' => '0xE282AA', '0xE1' => '0xD791', '0xE6' => '0xD796', |
|
| 3305 | + '0xE8' => '0xD798', '0xEB' => '0xD79B', '0xF4' => '0xD7A4', |
|
| 3306 | 3306 | '0xFA' => '0xD7AA', |
| 3307 | 3307 | ], |
| 3308 | 3308 | 'windows-1253' => [ |
| 3309 | - '0x81' => '\'\'', '0x88' => '\'\'', '0x8A' => '\'\'', |
|
| 3310 | - '0x8C' => '\'\'', '0x8D' => '\'\'', '0x8E' => '\'\'', |
|
| 3311 | - '0x8F' => '\'\'', '0x90' => '\'\'', '0x98' => '\'\'', |
|
| 3312 | - '0x9A' => '\'\'', '0x9C' => '\'\'', '0x9D' => '\'\'', |
|
| 3313 | - '0x9E' => '\'\'', '0x9F' => '\'\'', '0xAA' => '\'\'', |
|
| 3314 | - '0xD2' => '0xE282AC', '0xFF' => '0xCE92', '0xCE' => '0xCE9E', |
|
| 3315 | - '0xB8' => '0xCE88', '0xBA' => '0xCE8A', '0xBC' => '0xCE8C', |
|
| 3316 | - '0xBE' => '0xCE8E', '0xBF' => '0xCE8F', '0xC0' => '0xCE90', |
|
| 3317 | - '0xC8' => '0xCE98', '0xCA' => '0xCE9A', '0xCC' => '0xCE9C', |
|
| 3318 | - '0xCD' => '0xCE9D', '0xCF' => '0xCE9F', '0xDA' => '0xCEAA', |
|
| 3319 | - '0xE8' => '0xCEB8', '0xEA' => '0xCEBA', '0xEC' => '0xCEBC', |
|
| 3320 | - '0xEE' => '0xCEBE', '0xEF' => '0xCEBF', '0xC2' => '0xFF', |
|
| 3321 | - '0xBD' => '0xC2BD', '0xED' => '0xCEBD', '0xB2' => '0xC2B2', |
|
| 3322 | - '0xA0' => '0xC2A0', '0xA3' => '0xC2A3', '0xA4' => '0xC2A4', |
|
| 3323 | - '0xA5' => '0xC2A5', '0xA6' => '0xC2A6', '0xA7' => '0xC2A7', |
|
| 3324 | - '0xA8' => '0xC2A8', '0xA9' => '0xC2A9', '0xAB' => '0xC2AB', |
|
| 3325 | - '0xAC' => '0xC2AC', '0xAD' => '0xC2AD', '0xAE' => '0xC2AE', |
|
| 3326 | - '0xB0' => '0xC2B0', '0xB1' => '0xC2B1', '0xB3' => '0xC2B3', |
|
| 3327 | - '0xB5' => '0xC2B5', '0xB6' => '0xC2B6', '0xB7' => '0xC2B7', |
|
| 3328 | - '0xBB' => '0xC2BB', '0xE2' => '0xCEB2', '0x80' => '0xD2', |
|
| 3329 | - '0x82' => '0xE2809A', '0x84' => '0xE2809E', '0x85' => '0xE280A6', |
|
| 3330 | - '0x86' => '0xE280A0', '0xA1' => '0xCE85', '0xA2' => '0xCE86', |
|
| 3331 | - '0x87' => '0xE280A1', '0x89' => '0xE280B0', '0xB9' => '0xCE89', |
|
| 3332 | - '0x8B' => '0xE280B9', '0x91' => '0xE28098', '0x99' => '0xE284A2', |
|
| 3333 | - '0x92' => '0xE28099', '0x93' => '0xE2809C', '0x94' => '0xE2809D', |
|
| 3334 | - '0x95' => '0xE280A2', '0x96' => '0xE28093', '0x97' => '0xE28094', |
|
| 3335 | - '0x9B' => '0xE280BA', '0xAF' => '0xE28095', '0xB4' => '0xCE84', |
|
| 3336 | - '0xC1' => '0xCE91', '0xC3' => '0xCE93', '0xC4' => '0xCE94', |
|
| 3337 | - '0xC5' => '0xCE95', '0xC6' => '0xCE96', '0x83' => '0xC692', |
|
| 3338 | - '0xC7' => '0xCE97', '0xC9' => '0xCE99', '0xCB' => '0xCE9B', |
|
| 3339 | - '0xD0' => '0xCEA0', '0xD1' => '0xCEA1', '0xD3' => '0xCEA3', |
|
| 3340 | - '0xD4' => '0xCEA4', '0xD5' => '0xCEA5', '0xD6' => '0xCEA6', |
|
| 3341 | - '0xD7' => '0xCEA7', '0xD8' => '0xCEA8', '0xD9' => '0xCEA9', |
|
| 3342 | - '0xDB' => '0xCEAB', '0xDC' => '0xCEAC', '0xDD' => '0xCEAD', |
|
| 3343 | - '0xDE' => '0xCEAE', '0xDF' => '0xCEAF', '0xE0' => '0xCEB0', |
|
| 3344 | - '0xE1' => '0xCEB1', '0xE3' => '0xCEB3', '0xE4' => '0xCEB4', |
|
| 3345 | - '0xE5' => '0xCEB5', '0xE6' => '0xCEB6', '0xE7' => '0xCEB7', |
|
| 3346 | - '0xE9' => '0xCEB9', '0xEB' => '0xCEBB', '0xF0' => '0xCF80', |
|
| 3347 | - '0xF1' => '0xCF81', '0xF2' => '0xCF82', '0xF3' => '0xCF83', |
|
| 3348 | - '0xF4' => '0xCF84', '0xF5' => '0xCF85', '0xF6' => '0xCF86', |
|
| 3349 | - '0xF7' => '0xCF87', '0xF8' => '0xCF88', '0xF9' => '0xCF89', |
|
| 3350 | - '0xFA' => '0xCF8A', '0xFB' => '0xCF8B', '0xFC' => '0xCF8C', |
|
| 3351 | - '0xFD' => '0xCF8D', '0xFE' => '0xCF8E', |
|
| 3309 | + '0x81' => '\'\'', '0x88' => '\'\'', '0x8A' => '\'\'', |
|
| 3310 | + '0x8C' => '\'\'', '0x8D' => '\'\'', '0x8E' => '\'\'', |
|
| 3311 | + '0x8F' => '\'\'', '0x90' => '\'\'', '0x98' => '\'\'', |
|
| 3312 | + '0x9A' => '\'\'', '0x9C' => '\'\'', '0x9D' => '\'\'', |
|
| 3313 | + '0x9E' => '\'\'', '0x9F' => '\'\'', '0xAA' => '\'\'', |
|
| 3314 | + '0xD2' => '0xE282AC', '0xFF' => '0xCE92', '0xCE' => '0xCE9E', |
|
| 3315 | + '0xB8' => '0xCE88', '0xBA' => '0xCE8A', '0xBC' => '0xCE8C', |
|
| 3316 | + '0xBE' => '0xCE8E', '0xBF' => '0xCE8F', '0xC0' => '0xCE90', |
|
| 3317 | + '0xC8' => '0xCE98', '0xCA' => '0xCE9A', '0xCC' => '0xCE9C', |
|
| 3318 | + '0xCD' => '0xCE9D', '0xCF' => '0xCE9F', '0xDA' => '0xCEAA', |
|
| 3319 | + '0xE8' => '0xCEB8', '0xEA' => '0xCEBA', '0xEC' => '0xCEBC', |
|
| 3320 | + '0xEE' => '0xCEBE', '0xEF' => '0xCEBF', '0xC2' => '0xFF', |
|
| 3321 | + '0xBD' => '0xC2BD', '0xED' => '0xCEBD', '0xB2' => '0xC2B2', |
|
| 3322 | + '0xA0' => '0xC2A0', '0xA3' => '0xC2A3', '0xA4' => '0xC2A4', |
|
| 3323 | + '0xA5' => '0xC2A5', '0xA6' => '0xC2A6', '0xA7' => '0xC2A7', |
|
| 3324 | + '0xA8' => '0xC2A8', '0xA9' => '0xC2A9', '0xAB' => '0xC2AB', |
|
| 3325 | + '0xAC' => '0xC2AC', '0xAD' => '0xC2AD', '0xAE' => '0xC2AE', |
|
| 3326 | + '0xB0' => '0xC2B0', '0xB1' => '0xC2B1', '0xB3' => '0xC2B3', |
|
| 3327 | + '0xB5' => '0xC2B5', '0xB6' => '0xC2B6', '0xB7' => '0xC2B7', |
|
| 3328 | + '0xBB' => '0xC2BB', '0xE2' => '0xCEB2', '0x80' => '0xD2', |
|
| 3329 | + '0x82' => '0xE2809A', '0x84' => '0xE2809E', '0x85' => '0xE280A6', |
|
| 3330 | + '0x86' => '0xE280A0', '0xA1' => '0xCE85', '0xA2' => '0xCE86', |
|
| 3331 | + '0x87' => '0xE280A1', '0x89' => '0xE280B0', '0xB9' => '0xCE89', |
|
| 3332 | + '0x8B' => '0xE280B9', '0x91' => '0xE28098', '0x99' => '0xE284A2', |
|
| 3333 | + '0x92' => '0xE28099', '0x93' => '0xE2809C', '0x94' => '0xE2809D', |
|
| 3334 | + '0x95' => '0xE280A2', '0x96' => '0xE28093', '0x97' => '0xE28094', |
|
| 3335 | + '0x9B' => '0xE280BA', '0xAF' => '0xE28095', '0xB4' => '0xCE84', |
|
| 3336 | + '0xC1' => '0xCE91', '0xC3' => '0xCE93', '0xC4' => '0xCE94', |
|
| 3337 | + '0xC5' => '0xCE95', '0xC6' => '0xCE96', '0x83' => '0xC692', |
|
| 3338 | + '0xC7' => '0xCE97', '0xC9' => '0xCE99', '0xCB' => '0xCE9B', |
|
| 3339 | + '0xD0' => '0xCEA0', '0xD1' => '0xCEA1', '0xD3' => '0xCEA3', |
|
| 3340 | + '0xD4' => '0xCEA4', '0xD5' => '0xCEA5', '0xD6' => '0xCEA6', |
|
| 3341 | + '0xD7' => '0xCEA7', '0xD8' => '0xCEA8', '0xD9' => '0xCEA9', |
|
| 3342 | + '0xDB' => '0xCEAB', '0xDC' => '0xCEAC', '0xDD' => '0xCEAD', |
|
| 3343 | + '0xDE' => '0xCEAE', '0xDF' => '0xCEAF', '0xE0' => '0xCEB0', |
|
| 3344 | + '0xE1' => '0xCEB1', '0xE3' => '0xCEB3', '0xE4' => '0xCEB4', |
|
| 3345 | + '0xE5' => '0xCEB5', '0xE6' => '0xCEB6', '0xE7' => '0xCEB7', |
|
| 3346 | + '0xE9' => '0xCEB9', '0xEB' => '0xCEBB', '0xF0' => '0xCF80', |
|
| 3347 | + '0xF1' => '0xCF81', '0xF2' => '0xCF82', '0xF3' => '0xCF83', |
|
| 3348 | + '0xF4' => '0xCF84', '0xF5' => '0xCF85', '0xF6' => '0xCF86', |
|
| 3349 | + '0xF7' => '0xCF87', '0xF8' => '0xCF88', '0xF9' => '0xCF89', |
|
| 3350 | + '0xFA' => '0xCF8A', '0xFB' => '0xCF8B', '0xFC' => '0xCF8C', |
|
| 3351 | + '0xFD' => '0xCF8D', '0xFE' => '0xCF8E', |
|
| 3352 | 3352 | ], |
| 3353 | 3353 | ]; |
| 3354 | 3354 | |
@@ -3365,7 +3365,7 @@ discard block |
||
| 3365 | 3365 | // Get a list of table names ahead of time... This makes it easier to set our substep and such |
| 3366 | 3366 | $queryTables = Db::$db->list_tables(false, Config::$db_prefix . '%'); |
| 3367 | 3367 | |
| 3368 | - $queryTables = array_values(array_filter($queryTables, function ($v) { |
|
| 3368 | + $queryTables = array_values(array_filter($queryTables, function($v) { |
|
| 3369 | 3369 | return stripos($v, 'backup_') !== 0; |
| 3370 | 3370 | })); |
| 3371 | 3371 | |
@@ -3619,7 +3619,7 @@ discard block |
||
| 3619 | 3619 | // This bit fixes incorrect string lengths, which can happen if the character encoding was changed (e.g. conversion to UTF-8) |
| 3620 | 3620 | $new_string = preg_replace_callback( |
| 3621 | 3621 | '~\bs:(\d+):"(.*?)";(?=$|[bidsaO]:|[{}}]|N;)~s', |
| 3622 | - function ($matches) { |
|
| 3622 | + function($matches) { |
|
| 3623 | 3623 | return 's:' . strlen($matches[2]) . ':"' . $matches[2] . '";'; |
| 3624 | 3624 | }, |
| 3625 | 3625 | $string, |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | 'mysql' => [ |
| 69 | 69 | 'name' => 'MySQL', |
| 70 | 70 | 'version' => '5.6.0', |
| 71 | - 'version_check' => function () { |
|
| 71 | + 'version_check' => function() { |
|
| 72 | 72 | if (!function_exists('mysqli_fetch_row')) { |
| 73 | 73 | return false; |
| 74 | 74 | } |
@@ -80,15 +80,15 @@ discard block |
||
| 80 | 80 | 'default_password' => 'mysql.default_password', |
| 81 | 81 | 'default_host' => 'mysql.default_host', |
| 82 | 82 | 'default_port' => 'mysql.default_port', |
| 83 | - 'utf8_support' => function () { |
|
| 83 | + 'utf8_support' => function() { |
|
| 84 | 84 | return true; |
| 85 | 85 | }, |
| 86 | 86 | 'utf8_version' => '5.0.22', |
| 87 | - 'utf8_version_check' => function () { |
|
| 87 | + 'utf8_version_check' => function() { |
|
| 88 | 88 | return mysqli_get_server_info(Db::$db->connection); |
| 89 | 89 | }, |
| 90 | 90 | 'alter_support' => true, |
| 91 | - 'validate_prefix' => function (&$value) { |
|
| 91 | + 'validate_prefix' => function(&$value) { |
|
| 92 | 92 | $value = preg_replace('~[^A-Za-z0-9_\$]~', '', $value); |
| 93 | 93 | |
| 94 | 94 | return true; |
@@ -97,7 +97,7 @@ discard block |
||
| 97 | 97 | 'postgresql' => [ |
| 98 | 98 | 'name' => 'PostgreSQL', |
| 99 | 99 | 'version' => '9.6', |
| 100 | - 'version_check' => function () { |
|
| 100 | + 'version_check' => function() { |
|
| 101 | 101 | $request = pg_query(Db::$db->connection, 'SELECT version()'); |
| 102 | 102 | list($version) = pg_fetch_row($request); |
| 103 | 103 | list($pgl, $version) = explode(' ', $version); |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | }, |
| 107 | 107 | 'supported' => function_exists('pg_connect'), |
| 108 | 108 | 'always_has_db' => true, |
| 109 | - 'utf8_support' => function () { |
|
| 109 | + 'utf8_support' => function() { |
|
| 110 | 110 | $request = pg_query(Db::$db->connection, 'SHOW SERVER_ENCODING'); |
| 111 | 111 | |
| 112 | 112 | list($charcode) = pg_fetch_row($request); |
@@ -114,14 +114,14 @@ discard block |
||
| 114 | 114 | return (bool) ($charcode == 'UTF8'); |
| 115 | 115 | }, |
| 116 | 116 | 'utf8_version' => '8.0', |
| 117 | - 'utf8_version_check' => function () { |
|
| 117 | + 'utf8_version_check' => function() { |
|
| 118 | 118 | $request = pg_query(Db::$db->connection, 'SELECT version()'); |
| 119 | 119 | list($version) = pg_fetch_row($request); |
| 120 | 120 | list($pgl, $version) = explode(' ', $version); |
| 121 | 121 | |
| 122 | 122 | return $version; |
| 123 | 123 | }, |
| 124 | - 'validate_prefix' => function (&$value) { |
|
| 124 | + 'validate_prefix' => function(&$value) { |
|
| 125 | 125 | $value = preg_replace('~[^A-Za-z0-9_\$]~', '', $value); |
| 126 | 126 | |
| 127 | 127 | // Is it reserved? |
@@ -1692,7 +1692,7 @@ discard block |
||
| 1692 | 1692 | { |
| 1693 | 1693 | // Avoid double separators and empty titled sections |
| 1694 | 1694 | $empty_section = true; |
| 1695 | - for ($j=$i+1; $j < count(Utils::$context['theme_options']); $j++) |
|
| 1695 | + for ($j = $i + 1; $j < count(Utils::$context['theme_options']); $j++) |
|
| 1696 | 1696 | { |
| 1697 | 1697 | // Found another separator, so we're done |
| 1698 | 1698 | if (!is_array(Utils::$context['theme_options'][$j])) |
@@ -2687,8 +2687,7 @@ discard block |
||
| 2687 | 2687 | foreach (Utils::$context['post_errors'] as $error) |
| 2688 | 2688 | { |
| 2689 | 2689 | $text_key_error = $error == 'password_short' ? |
| 2690 | - sprintf(Lang::$txt['profile_error_' . $error], (empty(Config::$modSettings['password_strength']) ? 4 : 8)) : |
|
| 2691 | - (isset(Lang::$txt['profile_error_' . $error]) ? Lang::$txt['profile_error_' . $error] : ''); |
|
| 2690 | + sprintf(Lang::$txt['profile_error_' . $error], (empty(Config::$modSettings['password_strength']) ? 4 : 8)) : (isset(Lang::$txt['profile_error_' . $error]) ? Lang::$txt['profile_error_' . $error] : ''); |
|
| 2692 | 2691 | |
| 2693 | 2692 | echo ' |
| 2694 | 2693 | <li>', isset(Lang::$txt['profile_error_' . $error]) ? $text_key_error : $error, '</li>'; |
@@ -456,7 +456,7 @@ |
||
| 456 | 456 | |
| 457 | 457 | elseif (Utils::$context['uninstalling']) |
| 458 | 458 | echo ' |
| 459 | - ', Lang::$txt['package_uninstall_done'] .' <br> |
|
| 459 | + ', Lang::$txt['package_uninstall_done'] . ' <br> |
|
| 460 | 460 | ', '<a href="', Utils::$context['keep_url'], '" class="button">', Lang::$txt['package_keep'], '</a>', '<a href="', Utils::$context['remove_url'], '" class="button">', Lang::$txt['package_delete2'], '</a>'; |
| 461 | 461 | |
| 462 | 462 | elseif (Utils::$context['install_finished']) |
@@ -197,14 +197,14 @@ discard block |
||
| 197 | 197 | $report_buttons = array( |
| 198 | 198 | 'ignore' => array( |
| 199 | 199 | 'text' => !Utils::$context['report']['ignore'] ? 'mc_reportedp_ignore' : 'mc_reportedp_unignore', |
| 200 | - 'url' => Config::$scripturl.'?action=moderate;area=reportedposts;sa=handle;ignore='.(int) !Utils::$context['report']['ignore'].';rid='.Utils::$context['report']['id'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'].';'.Utils::$context['mod-report-ignore_token_var'].'='.Utils::$context['mod-report-ignore_token'], |
|
| 200 | + 'url' => Config::$scripturl . '?action=moderate;area=reportedposts;sa=handle;ignore=' . (int) !Utils::$context['report']['ignore'] . ';rid=' . Utils::$context['report']['id'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'] . ';' . Utils::$context['mod-report-ignore_token_var'] . '=' . Utils::$context['mod-report-ignore_token'], |
|
| 201 | 201 | 'class' => !Utils::$context['report']['ignore'] ? ' you_sure' : '', |
| 202 | 202 | 'custom' => !Utils::$context['report']['ignore'] ? ' data-confirm="' . Lang::$txt['mc_reportedp_ignore_confirm'] . '"' : '', |
| 203 | 203 | 'icon' => 'ignore' |
| 204 | 204 | ), |
| 205 | 205 | 'close' => array( |
| 206 | 206 | 'text' => Utils::$context['report']['closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', |
| 207 | - 'url' => Config::$scripturl.'?action=moderate;area=reportedposts;sa=handle;closed='.(int) !Utils::$context['report']['closed'].';rid='.Utils::$context['report']['id'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'].';'.Utils::$context['mod-report-closed_token_var'].'='.Utils::$context['mod-report-closed_token'], |
|
| 207 | + 'url' => Config::$scripturl . '?action=moderate;area=reportedposts;sa=handle;closed=' . (int) !Utils::$context['report']['closed'] . ';rid=' . Utils::$context['report']['id'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'] . ';' . Utils::$context['mod-report-closed_token_var'] . '=' . Utils::$context['mod-report-closed_token'], |
|
| 208 | 208 | 'icon' => 'close' |
| 209 | 209 | ) |
| 210 | 210 | ); |
@@ -479,14 +479,14 @@ discard block |
||
| 479 | 479 | $report_buttons = array( |
| 480 | 480 | 'ignore' => array( |
| 481 | 481 | 'text' => !Utils::$context['report']['ignore'] ? 'mc_reportedp_ignore' : 'mc_reportedp_unignore', |
| 482 | - 'url' => Config::$scripturl.'?action=moderate;area=reportedmembers;sa=handle;ignore='.(int)!Utils::$context['report']['ignore'].';rid='.Utils::$context['report']['id'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'].';'.Utils::$context['mod-report-ignore_token_var'].'='.Utils::$context['mod-report-ignore_token'], |
|
| 482 | + 'url' => Config::$scripturl . '?action=moderate;area=reportedmembers;sa=handle;ignore=' . (int) !Utils::$context['report']['ignore'] . ';rid=' . Utils::$context['report']['id'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'] . ';' . Utils::$context['mod-report-ignore_token_var'] . '=' . Utils::$context['mod-report-ignore_token'], |
|
| 483 | 483 | 'class' => !Utils::$context['report']['ignore'] ? ' you_sure' : '', |
| 484 | 484 | 'custom' => !Utils::$context['report']['ignore'] ? ' data-confirm="' . Lang::$txt['mc_reportedp_ignore_confirm'] . '"' : '', |
| 485 | 485 | 'icon' => 'ignore' |
| 486 | 486 | ), |
| 487 | 487 | 'close' => array( |
| 488 | 488 | 'text' => Utils::$context['report']['closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', |
| 489 | - 'url' => Config::$scripturl.'?action=moderate;area=reportedmembers;sa=handle;closed='.(int)!Utils::$context['report']['closed'].';rid='.Utils::$context['report']['id'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'].';'.Utils::$context['mod-report-closed_token_var'].'='.Utils::$context['mod-report-closed_token'], |
|
| 489 | + 'url' => Config::$scripturl . '?action=moderate;area=reportedmembers;sa=handle;closed=' . (int) !Utils::$context['report']['closed'] . ';rid=' . Utils::$context['report']['id'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'] . ';' . Utils::$context['mod-report-closed_token_var'] . '=' . Utils::$context['mod-report-closed_token'], |
|
| 490 | 490 | 'icon' => 'close' |
| 491 | 491 | ) |
| 492 | 492 | ); |
@@ -275,7 +275,7 @@ discard block |
||
| 275 | 275 | ', sprintf(Lang::$txt['welcome_to_forum'], Utils::$context['forum_name_html_safe']), ' |
| 276 | 276 | </li> |
| 277 | 277 | <li class="button_login"> |
| 278 | - <a href="', Config::$scripturl, '?action=login" class="', Utils::$context['current_action'] == 'login' ? 'active' : 'open','" onclick="return reqOverlayDiv(this.href, ' . Utils::JavaScriptEscape(Lang::$txt['login']) . ', \'login\');"> |
|
| 278 | + <a href="', Config::$scripturl, '?action=login" class="', Utils::$context['current_action'] == 'login' ? 'active' : 'open', '" onclick="return reqOverlayDiv(this.href, ' . Utils::JavaScriptEscape(Lang::$txt['login']) . ', \'login\');"> |
|
| 279 | 279 | <span class="main_icons login"></span> |
| 280 | 280 | <span class="textmenu">', Lang::$txt['login'], '</span> |
| 281 | 281 | </a> |
@@ -284,7 +284,7 @@ discard block |
||
| 284 | 284 | if (Utils::$context['can_register']) |
| 285 | 285 | echo ' |
| 286 | 286 | <li class="button_signup"> |
| 287 | - <a href="', Config::$scripturl, '?action=signup" class="', Utils::$context['current_action'] == 'signup' ? 'active' : 'open','"> |
|
| 287 | + <a href="', Config::$scripturl, '?action=signup" class="', Utils::$context['current_action'] == 'signup' ? 'active' : 'open', '"> |
|
| 288 | 288 | <span class="main_icons regcenter"></span> |
| 289 | 289 | <span class="textmenu">', Lang::$txt['register'], '</span> |
| 290 | 290 | </a> |
@@ -632,7 +632,7 @@ discard block |
||
| 632 | 632 | $value['id'] = $key; |
| 633 | 633 | |
| 634 | 634 | $button = ' |
| 635 | - <a class="button button_strip_' . $key . (!empty($value['active']) ? ' active' : '') . (isset($value['class']) ? ' ' . $value['class'] : '') . '" ' . (!empty($value['url']) ? 'href="' . $value['url'] . '"' : '') . ' ' . (isset($value['custom']) ? ' ' . $value['custom'] : '') . '>'.(!empty($value['icon']) ? '<span class="main_icons '.$value['icon'].'"></span>' : '').'' . Lang::$txt[$value['text']] . '</a>'; |
|
| 635 | + <a class="button button_strip_' . $key . (!empty($value['active']) ? ' active' : '') . (isset($value['class']) ? ' ' . $value['class'] : '') . '" ' . (!empty($value['url']) ? 'href="' . $value['url'] . '"' : '') . ' ' . (isset($value['custom']) ? ' ' . $value['custom'] : '') . '>' . (!empty($value['icon']) ? '<span class="main_icons ' . $value['icon'] . '"></span>' : '') . '' . Lang::$txt[$value['text']] . '</a>'; |
|
| 636 | 636 | |
| 637 | 637 | if (!empty($value['sub_buttons'])) |
| 638 | 638 | { |
@@ -399,18 +399,18 @@ discard block |
||
| 399 | 399 | $quickbuttons = array( |
| 400 | 400 | 'approve' => array( |
| 401 | 401 | 'label' => Lang::$txt['approve'], |
| 402 | - 'href' => Config::$scripturl.'?action=moderate;area=postmod;sa='.Utils::$context['current_view'].';start='.Utils::$context['start'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'].';approve='.$item['id'], |
|
| 402 | + 'href' => Config::$scripturl . '?action=moderate;area=postmod;sa=' . Utils::$context['current_view'] . ';start=' . Utils::$context['start'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'] . ';approve=' . $item['id'], |
|
| 403 | 403 | 'icon' => 'approve', |
| 404 | 404 | ), |
| 405 | 405 | 'delete' => array( |
| 406 | 406 | 'label' => Lang::$txt['remove'], |
| 407 | - 'href' => Config::$scripturl.'?action=moderate;area=postmod;sa='.Utils::$context['current_view'].';start='.Utils::$context['start'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'].';delete='.$item['id'], |
|
| 407 | + 'href' => Config::$scripturl . '?action=moderate;area=postmod;sa=' . Utils::$context['current_view'] . ';start=' . Utils::$context['start'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'] . ';delete=' . $item['id'], |
|
| 408 | 408 | 'icon' => 'remove_button', |
| 409 | 409 | 'show' => $item['can_delete'] |
| 410 | 410 | ), |
| 411 | 411 | 'quickmod' => array( |
| 412 | 412 | 'class' => 'inline_mod_check', |
| 413 | - 'content' => '<input type="checkbox" name="item[]" value="'.$item['id'].'" checked>', |
|
| 413 | + 'content' => '<input type="checkbox" name="item[]" value="' . $item['id'] . '" checked>', |
|
| 414 | 414 | 'show' => !empty(Theme::$current->options['display_quick_mod']) && Theme::$current->options['display_quick_mod'] == 1 |
| 415 | 415 | ), |
| 416 | 416 | ); |
@@ -471,7 +471,7 @@ discard block |
||
| 471 | 471 | $quickbuttons = array( |
| 472 | 472 | 'delete' => array( |
| 473 | 473 | 'label' => Lang::$txt['remove_message'], |
| 474 | - 'href' => Config::$scripturl.'?action=moderate;area=userwatch;sa=post;delete='.$post['id'].';start='.Utils::$context['start'].';'.Utils::$context['session_var'].'='.Utils::$context['session_id'], |
|
| 474 | + 'href' => Config::$scripturl . '?action=moderate;area=userwatch;sa=post;delete=' . $post['id'] . ';start=' . Utils::$context['start'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'], |
|
| 475 | 475 | 'javascript' => 'data-confirm="' . Lang::$txt['mc_watched_users_delete_post'] . '"', |
| 476 | 476 | 'class' => 'you_sure', |
| 477 | 477 | 'icon' => 'remove_button', |