@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -22,10 +22,10 @@ discard block |
||
| 22 | 22 | |
| 23 | 23 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 24 | 24 | $protocol = 'http'; |
| 25 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 25 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 26 | 26 | $protocol = 'https'; |
| 27 | 27 | } |
| 28 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 28 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 29 | 29 | exit(); |
| 30 | 30 | } |
| 31 | 31 | |
@@ -47,18 +47,18 @@ discard block |
||
| 47 | 47 | |
| 48 | 48 | $text = []; |
| 49 | 49 | $text[0] = []; |
| 50 | - ($useCategory) ? $text[0][] = $PMF_LANG['ad_stat_report_category'] : ''; |
|
| 51 | - ($useSubcategory) ? $text[0][] = $PMF_LANG['ad_stat_report_sub_category'] : ''; |
|
| 52 | - ($useTranslation) ? $text[0][] = $PMF_LANG['ad_stat_report_translations'] : ''; |
|
| 53 | - ($useLanguage) ? $text[0][] = $PMF_LANG['ad_stat_report_language'] : ''; |
|
| 54 | - ($useId) ? $text[0][] = $PMF_LANG['ad_stat_report_id'] : ''; |
|
| 55 | - ($useSticky) ? $text[0][] = $PMF_LANG['ad_stat_report_sticky'] : ''; |
|
| 56 | - ($useTitle) ? $text[0][] = $PMF_LANG['ad_stat_report_title'] : ''; |
|
| 50 | + ($useCategory) ? $text[0][] = $PMF_LANG['ad_stat_report_category'] : ''; |
|
| 51 | + ($useSubcategory) ? $text[0][] = $PMF_LANG['ad_stat_report_sub_category'] : ''; |
|
| 52 | + ($useTranslation) ? $text[0][] = $PMF_LANG['ad_stat_report_translations'] : ''; |
|
| 53 | + ($useLanguage) ? $text[0][] = $PMF_LANG['ad_stat_report_language'] : ''; |
|
| 54 | + ($useId) ? $text[0][] = $PMF_LANG['ad_stat_report_id'] : ''; |
|
| 55 | + ($useSticky) ? $text[0][] = $PMF_LANG['ad_stat_report_sticky'] : ''; |
|
| 56 | + ($useTitle) ? $text[0][] = $PMF_LANG['ad_stat_report_title'] : ''; |
|
| 57 | 57 | ($useCreationDate) ? $text[0][] = $PMF_LANG['ad_stat_report_creation_date'] : ''; |
| 58 | - ($useOwner) ? $text[0][] = $PMF_LANG['ad_stat_report_owner'] : ''; |
|
| 58 | + ($useOwner) ? $text[0][] = $PMF_LANG['ad_stat_report_owner'] : ''; |
|
| 59 | 59 | ($useLastModified) ? $text[0][] = $PMF_LANG['ad_stat_report_last_modified_person'] : ''; |
| 60 | - ($useUrl) ? $text[0][] = $PMF_LANG['ad_stat_report_url'] : ''; |
|
| 61 | - ($useVisits) ? $text[0][] = $PMF_LANG['ad_stat_report_visits'] : ''; |
|
| 60 | + ($useUrl) ? $text[0][] = $PMF_LANG['ad_stat_report_url'] : ''; |
|
| 61 | + ($useVisits) ? $text[0][] = $PMF_LANG['ad_stat_report_visits'] : ''; |
|
| 62 | 62 | |
| 63 | 63 | $report = new PMF_Report($faqConfig); |
| 64 | 64 | |
@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -19,10 +19,10 @@ |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -19,10 +19,10 @@ discard block |
||
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
| 22 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
| 22 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
| 23 | 23 | $protocol = 'https'; |
| 24 | 24 | } |
| 25 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
| 25 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
| 26 | 26 | exit(); |
| 27 | 27 | } |
| 28 | 28 | |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | |
| 41 | 41 | if (isset($_FILES['userfile']) && 0 == $_FILES['userfile']['error']) { |
| 42 | 42 | |
| 43 | - $ok = 1; |
|
| 43 | + $ok = 1; |
|
| 44 | 44 | $finfo = new finfo(FILEINFO_MIME_ENCODING); |
| 45 | 45 | if ('utf-8' == $finfo->file($_FILES['userfile']['tmp_name'])) { |
| 46 | 46 | print 'This file is not UTF_8 encoded.'; |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | $handle = fopen($_FILES['userfile']['tmp_name'], 'r'); |
| 50 | 50 | $dat = fgets($handle, 65536); |
| 51 | 51 | $versionFound = PMF_String::substr($dat, 0, 9); |
| 52 | - $versionExpected = '-- pmf' . substr($faqConfig->get('main.currentVersion'), 0, 3); |
|
| 52 | + $versionExpected = '-- pmf'.substr($faqConfig->get('main.currentVersion'), 0, 3); |
|
| 53 | 53 | |
| 54 | 54 | if ($versionFound != $versionExpected) { |
| 55 | 55 | printf('%s (Version check failure: "%s" found, "%s" expected)', |
@@ -79,7 +79,7 @@ discard block |
||
| 79 | 79 | if (PMF_String::substr($dat, 0, $backup_prefix_pattern_len) == $backup_prefix_pattern) { |
| 80 | 80 | $table_prefix = trim(PMF_String::substr($dat, $backup_prefix_pattern_len)); |
| 81 | 81 | } |
| 82 | - if ( (PMF_String::substr($dat, 0, 2) != '--') && ($dat != '') ) { |
|
| 82 | + if ((PMF_String::substr($dat, 0, 2) != '--') && ($dat != '')) { |
|
| 83 | 83 | $mquery[] = trim(PMF_String::substr($dat, 0, -1)); |
| 84 | 84 | } |
| 85 | 85 | } |