@@ -1,22 +1,22 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Export of a generated report |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Gustavo Solt <[email protected]> |
|
14 | - * @author Thorsten Rinne <[email protected]> |
|
15 | - * @copyright 2011-2015 phpMyFAQ Team |
|
16 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | - * @link http://www.phpmyfaq.de |
|
18 | - * @since 2011-01-12 |
|
19 | - */ |
|
3 | + * Export of a generated report |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Gustavo Solt <[email protected]> |
|
14 | + * @author Thorsten Rinne <[email protected]> |
|
15 | + * @copyright 2011-2015 phpMyFAQ Team |
|
16 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | + * @link http://www.phpmyfaq.de |
|
18 | + * @since 2011-01-12 |
|
19 | + */ |
|
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
@@ -20,10 +20,10 @@ discard block |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 | |
@@ -45,18 +45,18 @@ discard block |
||
45 | 45 | |
46 | 46 | $text = array(); |
47 | 47 | $text[0] = array(); |
48 | - ($useCategory) ? $text[0][] = $PMF_LANG['ad_stat_report_category'] : ''; |
|
49 | - ($useSubcategory) ? $text[0][] = $PMF_LANG['ad_stat_report_sub_category'] : ''; |
|
50 | - ($useTranslation) ? $text[0][] = $PMF_LANG['ad_stat_report_translations'] : ''; |
|
51 | - ($useLanguage) ? $text[0][] = $PMF_LANG['ad_stat_report_language'] : ''; |
|
52 | - ($useId) ? $text[0][] = $PMF_LANG['ad_stat_report_id'] : ''; |
|
53 | - ($useSticky) ? $text[0][] = $PMF_LANG['ad_stat_report_sticky'] : ''; |
|
54 | - ($useTitle) ? $text[0][] = $PMF_LANG['ad_stat_report_title'] : ''; |
|
48 | + ($useCategory) ? $text[0][] = $PMF_LANG['ad_stat_report_category'] : ''; |
|
49 | + ($useSubcategory) ? $text[0][] = $PMF_LANG['ad_stat_report_sub_category'] : ''; |
|
50 | + ($useTranslation) ? $text[0][] = $PMF_LANG['ad_stat_report_translations'] : ''; |
|
51 | + ($useLanguage) ? $text[0][] = $PMF_LANG['ad_stat_report_language'] : ''; |
|
52 | + ($useId) ? $text[0][] = $PMF_LANG['ad_stat_report_id'] : ''; |
|
53 | + ($useSticky) ? $text[0][] = $PMF_LANG['ad_stat_report_sticky'] : ''; |
|
54 | + ($useTitle) ? $text[0][] = $PMF_LANG['ad_stat_report_title'] : ''; |
|
55 | 55 | ($useCreationDate) ? $text[0][] = $PMF_LANG['ad_stat_report_creation_date'] : ''; |
56 | - ($useOwner) ? $text[0][] = $PMF_LANG['ad_stat_report_owner'] : ''; |
|
56 | + ($useOwner) ? $text[0][] = $PMF_LANG['ad_stat_report_owner'] : ''; |
|
57 | 57 | ($useLastModified) ? $text[0][] = $PMF_LANG['ad_stat_report_last_modified_person'] : ''; |
58 | - ($useUrl) ? $text[0][] = $PMF_LANG['ad_stat_report_url'] : ''; |
|
59 | - ($useVisits) ? $text[0][] = $PMF_LANG['ad_stat_report_visits'] : ''; |
|
58 | + ($useUrl) ? $text[0][] = $PMF_LANG['ad_stat_report_url'] : ''; |
|
59 | + ($useVisits) ? $text[0][] = $PMF_LANG['ad_stat_report_visits'] : ''; |
|
60 | 60 | |
61 | 61 | $report = new PMF_Report($faqConfig); |
62 | 62 |
@@ -1,22 +1,22 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * The reporting page |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Gustavo Solt <[email protected]> |
|
14 | - * @author Thorsten Rinne <[email protected]> |
|
15 | - * @copyright 2011-2015 phpMyFAQ Team |
|
16 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | - * @link http://www.phpmyfaq.de |
|
18 | - * @since 2011-01-12 |
|
19 | - */ |
|
3 | + * The reporting page |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Gustavo Solt <[email protected]> |
|
14 | + * @author Thorsten Rinne <[email protected]> |
|
15 | + * @copyright 2011-2015 phpMyFAQ Team |
|
16 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | + * @link http://www.phpmyfaq.de |
|
18 | + * @since 2011-01-12 |
|
19 | + */ |
|
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
@@ -20,10 +20,10 @@ |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 |
@@ -20,19 +20,19 @@ discard block |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 | |
30 | 30 | clearstatcache(); |
31 | -if(isset($_SESSION['trans'])) { |
|
31 | +if (isset($_SESSION['trans'])) { |
|
32 | 32 | unset($_SESSION['trans']); |
33 | 33 | } |
34 | 34 | |
35 | -$langDir = PMF_ROOT_DIR . DIRECTORY_SEPARATOR . "lang"; |
|
35 | +$langDir = PMF_ROOT_DIR.DIRECTORY_SEPARATOR."lang"; |
|
36 | 36 | $transDir = new DirectoryIterator($langDir); |
37 | 37 | $isTransDirWritable = is_writable($langDir); |
38 | 38 | $tt = new PMF_TransTool; |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | <header> |
41 | 41 | <h2> |
42 | 42 | <i class="icon-wrench"></i> <?php echo $PMF_LANG['ad_menu_translations'] ?> |
43 | - <?php if($permission["addtranslation"] && $isTransDirWritable): ?> |
|
43 | + <?php if ($permission["addtranslation"] && $isTransDirWritable): ?> |
|
44 | 44 | <div class="pull-right"> |
45 | 45 | <a class="btn btn-success" href="?action=transadd"> |
46 | 46 | <i class="icon-plus"></i> <?php echo $PMF_LANG['msgTransToolAddNewTranslation'] ?> |
@@ -52,8 +52,8 @@ discard block |
||
52 | 52 | |
53 | 53 | <p><?php echo $PMF_LANG['msgChooseLanguageToTranslate'] ?>:</p> |
54 | 54 | |
55 | - <?php if(!$isTransDirWritable): |
|
56 | - echo '<p class="alert alert-error">'. $PMF_LANG['msgLangDirIsntWritable'] . "</p>"; |
|
55 | + <?php if (!$isTransDirWritable): |
|
56 | + echo '<p class="alert alert-error">'.$PMF_LANG['msgLangDirIsntWritable']."</p>"; |
|
57 | 57 | endif; ?> |
58 | 58 | |
59 | 59 | <table class="table table-striped"> |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | /** |
77 | 77 | * English is our exemplary language which won't be changed |
78 | 78 | */ |
79 | - if('en' == $lang) { |
|
79 | + if ('en' == $lang) { |
|
80 | 80 | continue; |
81 | 81 | } |
82 | 82 | |
@@ -87,12 +87,12 @@ discard block |
||
87 | 87 | sort($sortedLangList); |
88 | 88 | |
89 | 89 | while (list(,$lang) = each($sortedLangList)) { |
90 | - $isLangFileWritable = is_writable($langDir . DIRECTORY_SEPARATOR . "language_$lang.php"); |
|
90 | + $isLangFileWritable = is_writable($langDir.DIRECTORY_SEPARATOR."language_$lang.php"); |
|
91 | 91 | $showActions = $isTransDirWritable && $isLangFileWritable; |
92 | 92 | ?> |
93 | 93 | <tr class="lang_<?php echo $lang ?>_container"> |
94 | 94 | <td><?php echo $languageCodes[strtoupper($lang)] ?></td> |
95 | - <?php if($permission["edittranslation"] && $showActions): ?> |
|
95 | + <?php if ($permission["edittranslation"] && $showActions): ?> |
|
96 | 96 | <td> |
97 | 97 | <a class="btn btn-primary" href="?action=transedit&translang=<?php echo $lang ?>" > |
98 | 98 | <i class="icon-edit icon-white"></i> |
@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | <?php else: ?> |
103 | 103 | <td><?php echo $PMF_LANG['msgEdit'] ?></td> |
104 | 104 | <?php endif; ?> |
105 | - <?php if($permission["deltranslation"] && $showActions): ?> |
|
105 | + <?php if ($permission["deltranslation"] && $showActions): ?> |
|
106 | 106 | <td> |
107 | 107 | <a class="btn btn-danger" href="javascript: del('<?php echo $lang ?>');" > |
108 | 108 | <i class="icon-remove icon-white"></i> |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | <?php else: ?> |
113 | 113 | <td><?php echo $PMF_LANG['msgDelete'] ?></td> |
114 | 114 | <?php endif; ?> |
115 | - <?php if($permission["edittranslation"] && $showActions): ?> |
|
115 | + <?php if ($permission["edittranslation"] && $showActions): ?> |
|
116 | 116 | <td> |
117 | 117 | <a class="btn btn-success" href="javascript: sendToTeam('<?php echo $lang ?>');" > |
118 | 118 | <i class="icon-upload icon-white"></i> |
@@ -121,15 +121,15 @@ discard block |
||
121 | 121 | </td> |
122 | 122 | <?php else: ?> |
123 | 123 | <td><?php echo $PMF_LANG['msgTransToolSendToTeam'] ?></td> |
124 | - <?php endif;?> |
|
125 | - <?php if($isLangFileWritable): ?> |
|
124 | + <?php endif; ?> |
|
125 | + <?php if ($isLangFileWritable): ?> |
|
126 | 126 | <td><i class="icon-ok-circle"></i> <?php echo $PMF_LANG['msgYes'] ?></td> |
127 | 127 | <?php else: ?> |
128 | 128 | <td><i class="icon-ban-circle"></i> <?php echo $PMF_LANG['msgNo'] ?></td> |
129 | 129 | <?php endif; ?> |
130 | 130 | <td><?php echo $tt->getTranslatedPercentage( |
131 | - $langDir . DIRECTORY_SEPARATOR . "language_en.php", |
|
132 | - $langDir . DIRECTORY_SEPARATOR . "language_$lang.php" |
|
131 | + $langDir.DIRECTORY_SEPARATOR."language_en.php", |
|
132 | + $langDir.DIRECTORY_SEPARATOR."language_$lang.php" |
|
133 | 133 | ); ?>%</td> |
134 | 134 | </tr> |
135 | 135 | <?php |
@@ -99,9 +99,12 @@ discard block |
||
99 | 99 | <?php echo $PMF_LANG['msgEdit'] ?> |
100 | 100 | </a> |
101 | 101 | </td> |
102 | - <?php else: ?> |
|
102 | + <?php else { |
|
103 | + : ?> |
|
103 | 104 | <td><?php echo $PMF_LANG['msgEdit'] ?></td> |
104 | - <?php endif; ?> |
|
105 | + <?php endif; |
|
106 | +} |
|
107 | +?> |
|
105 | 108 | <?php if($permission["deltranslation"] && $showActions): ?> |
106 | 109 | <td> |
107 | 110 | <a class="btn btn-danger" href="javascript: del('<?php echo $lang ?>');" > |
@@ -109,9 +112,12 @@ discard block |
||
109 | 112 | <?php echo $PMF_LANG['msgDelete'] ?> |
110 | 113 | </a> |
111 | 114 | </td> |
112 | - <?php else: ?> |
|
115 | + <?php else { |
|
116 | + : ?> |
|
113 | 117 | <td><?php echo $PMF_LANG['msgDelete'] ?></td> |
114 | - <?php endif; ?> |
|
118 | + <?php endif; |
|
119 | +} |
|
120 | +?> |
|
115 | 121 | <?php if($permission["edittranslation"] && $showActions): ?> |
116 | 122 | <td> |
117 | 123 | <a class="btn btn-success" href="javascript: sendToTeam('<?php echo $lang ?>');" > |
@@ -119,14 +125,20 @@ discard block |
||
119 | 125 | <?php echo $PMF_LANG['msgTransToolSendToTeam'] ?> |
120 | 126 | </a> |
121 | 127 | </td> |
122 | - <?php else: ?> |
|
128 | + <?php else { |
|
129 | + : ?> |
|
123 | 130 | <td><?php echo $PMF_LANG['msgTransToolSendToTeam'] ?></td> |
124 | - <?php endif;?> |
|
131 | + <?php endif; |
|
132 | +} |
|
133 | +?> |
|
125 | 134 | <?php if($isLangFileWritable): ?> |
126 | 135 | <td><i class="icon-ok-circle"></i> <?php echo $PMF_LANG['msgYes'] ?></td> |
127 | - <?php else: ?> |
|
136 | + <?php else { |
|
137 | + : ?> |
|
128 | 138 | <td><i class="icon-ban-circle"></i> <?php echo $PMF_LANG['msgNo'] ?></td> |
129 | - <?php endif; ?> |
|
139 | + <?php endif; |
|
140 | +} |
|
141 | +?> |
|
130 | 142 | <td><?php echo $tt->getTranslatedPercentage( |
131 | 143 | $langDir . DIRECTORY_SEPARATOR . "language_en.php", |
132 | 144 | $langDir . DIRECTORY_SEPARATOR . "language_$lang.php" |
@@ -1,22 +1,22 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * List avaliable interface translations and actions |
|
4 | - * depending on user right |
|
5 | - * |
|
6 | - * PHP Version 5.3 |
|
7 | - * |
|
8 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
9 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
10 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
11 | - * |
|
12 | - * @category phpMyFAQ |
|
13 | - * @package Administration |
|
14 | - * @author Anatoliy Belsky <[email protected]> |
|
15 | - * @copyright 2009-2015 phpMyFAQ Team |
|
16 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | - * @link http://www.phpmyfaq.de |
|
18 | - * @since 2009-05-11 |
|
19 | - */ |
|
3 | + * List avaliable interface translations and actions |
|
4 | + * depending on user right |
|
5 | + * |
|
6 | + * PHP Version 5.3 |
|
7 | + * |
|
8 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
9 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
10 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
11 | + * |
|
12 | + * @category phpMyFAQ |
|
13 | + * @package Administration |
|
14 | + * @author Anatoliy Belsky <[email protected]> |
|
15 | + * @copyright 2009-2015 phpMyFAQ Team |
|
16 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | + * @link http://www.phpmyfaq.de |
|
18 | + * @since 2009-05-11 |
|
19 | + */ |
|
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
@@ -1,21 +1,21 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Edits a category |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Thorsten Rinne <[email protected]> |
|
14 | - * @copyright 2003-2015 phpMyFAQ Team |
|
15 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
16 | - * @link http://www.phpmyfaq.de |
|
17 | - * @since 2003-03-10 |
|
18 | - */ |
|
3 | + * Edits a category |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Thorsten Rinne <[email protected]> |
|
14 | + * @copyright 2003-2015 phpMyFAQ Team |
|
15 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
16 | + * @link http://www.phpmyfaq.de |
|
17 | + * @since 2003-03-10 |
|
18 | + */ |
|
19 | 19 | |
20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
21 | 21 | $protocol = 'http'; |
@@ -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 | |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | $restrictedGroups = true; |
53 | 53 | } |
54 | 54 | |
55 | - $header = $PMF_LANG['ad_categ_edit_1'] . ' ' . $categories[$categoryId]['name'] . ' ' . $PMF_LANG['ad_categ_edit_2']; |
|
55 | + $header = $PMF_LANG['ad_categ_edit_1'].' '.$categories[$categoryId]['name'].' '.$PMF_LANG['ad_categ_edit_2']; |
|
56 | 56 | ?> |
57 | 57 | |
58 | 58 | <header> |
@@ -1,22 +1,22 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * build table of all categories in all languages |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Thorsten Rinne <[email protected]> |
|
14 | - * @author Rudi Ferrari <[email protected]> |
|
15 | - * @copyright 2006-2015 phpMyFAQ Team |
|
16 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | - * @link http://www.phpmyfaq.de |
|
18 | - * @since 2006-09-18 |
|
19 | - */ |
|
3 | + * build table of all categories in all languages |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Thorsten Rinne <[email protected]> |
|
14 | + * @author Rudi Ferrari <[email protected]> |
|
15 | + * @copyright 2006-2015 phpMyFAQ Team |
|
16 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | + * @link http://www.phpmyfaq.de |
|
18 | + * @since 2006-09-18 |
|
19 | + */ |
|
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
@@ -74,13 +74,13 @@ discard block |
||
74 | 74 | // get languages in use for all categories |
75 | 75 | $all_languages = $faqConfig->getLanguage()->languageAvailable(0, $table='faqcategories'); |
76 | 76 | foreach ($all_languages as $lang) { |
77 | - $all_lang[$lang] = $languageCodes[strtoupper($lang)]; |
|
77 | + $all_lang[$lang] = $languageCodes[strtoupper($lang)]; |
|
78 | 78 | } |
79 | 79 | asort($all_lang); |
80 | 80 | foreach($all_lang as $lang => $language) { |
81 | - if ($language != $currentLanguage) { |
|
82 | - printf("<th>" . $language . "</th>\n", $language); |
|
83 | - } |
|
81 | + if ($language != $currentLanguage) { |
|
82 | + printf("<th>" . $language . "</th>\n", $language); |
|
83 | + } |
|
84 | 84 | } |
85 | 85 | ?> |
86 | 86 | </tr> |
@@ -101,15 +101,15 @@ discard block |
||
101 | 101 | // show category name in actual language |
102 | 102 | print '<td>'; |
103 | 103 | if ($cat['lang'] != $LANGCODE) { |
104 | - // translate category |
|
105 | - printf( |
|
106 | - '<a href="%s?action=translatecategory&cat=%s&trlang=%s" title="%s"><span title="%s" class="icon-share"></span></a></a>', |
|
107 | - $currentLink, |
|
108 | - $cat['id'], |
|
109 | - $LANGCODE, |
|
110 | - $PMF_LANG['ad_categ_translate'], |
|
111 | - $PMF_LANG['ad_categ_translate'] |
|
112 | - ); |
|
104 | + // translate category |
|
105 | + printf( |
|
106 | + '<a href="%s?action=translatecategory&cat=%s&trlang=%s" title="%s"><span title="%s" class="icon-share"></span></a></a>', |
|
107 | + $currentLink, |
|
108 | + $cat['id'], |
|
109 | + $LANGCODE, |
|
110 | + $PMF_LANG['ad_categ_translate'], |
|
111 | + $PMF_LANG['ad_categ_translate'] |
|
112 | + ); |
|
113 | 113 | } |
114 | 114 | printf(" %s<strong>%s</strong>", |
115 | 115 | $indent, |
@@ -20,10 +20,10 @@ discard block |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 | |
@@ -72,14 +72,14 @@ discard block |
||
72 | 72 | <th><?php print $currentLanguage ?></th> |
73 | 73 | <?php |
74 | 74 | // get languages in use for all categories |
75 | - $all_languages = $faqConfig->getLanguage()->languageAvailable(0, $table='faqcategories'); |
|
75 | + $all_languages = $faqConfig->getLanguage()->languageAvailable(0, $table = 'faqcategories'); |
|
76 | 76 | foreach ($all_languages as $lang) { |
77 | 77 | $all_lang[$lang] = $languageCodes[strtoupper($lang)]; |
78 | 78 | } |
79 | 79 | asort($all_lang); |
80 | - foreach($all_lang as $lang => $language) { |
|
80 | + foreach ($all_lang as $lang => $language) { |
|
81 | 81 | if ($language != $currentLanguage) { |
82 | - printf("<th>" . $language . "</th>\n", $language); |
|
82 | + printf("<th>".$language."</th>\n", $language); |
|
83 | 83 | } |
84 | 84 | } |
85 | 85 | ?> |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | // get languages in use for categories |
121 | 121 | $id_languages = $category->getCategoryLanguagesTranslated($cat["id"]); |
122 | 122 | |
123 | - foreach($all_lang as $lang => $language) { |
|
123 | + foreach ($all_lang as $lang => $language) { |
|
124 | 124 | if ($language == $currentLanguage) { |
125 | 125 | continue; |
126 | 126 | } |
@@ -1,22 +1,22 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Adds a new (sub-)category, a new sub-category inherits the permissions from |
|
4 | - * its parent category. |
|
5 | - * |
|
6 | - * PHP Version 5.3 |
|
7 | - * |
|
8 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
9 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
10 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
11 | - * |
|
12 | - * @category phpMyFAQ |
|
13 | - * @package Administration |
|
14 | - * @author Thorsten Rinne <[email protected]> |
|
15 | - * @copyright 2003-2015 phpMyFAQ Team |
|
16 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | - * @link http://www.phpmyfaq.de |
|
18 | - * @since 2003-12-20 |
|
19 | - */ |
|
3 | + * Adds a new (sub-)category, a new sub-category inherits the permissions from |
|
4 | + * its parent category. |
|
5 | + * |
|
6 | + * PHP Version 5.3 |
|
7 | + * |
|
8 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
9 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
10 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
11 | + * |
|
12 | + * @category phpMyFAQ |
|
13 | + * @package Administration |
|
14 | + * @author Thorsten Rinne <[email protected]> |
|
15 | + * @copyright 2003-2015 phpMyFAQ Team |
|
16 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | + * @link http://www.phpmyfaq.de |
|
18 | + * @since 2003-12-20 |
|
19 | + */ |
|
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
@@ -20,10 +20,10 @@ |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 |
@@ -1,22 +1,22 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * phpMyFAQ system informations |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Thorsten Rinne <[email protected]> |
|
14 | - * @author Matteo Scaramuccia <[email protected]> |
|
15 | - * @copyright 2013-2015 phpMyFAQ Team |
|
16 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | - * @link http://www.phpmyfaq.de |
|
18 | - * @since 2013-01-02 |
|
19 | - */ |
|
3 | + * phpMyFAQ system informations |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Thorsten Rinne <[email protected]> |
|
14 | + * @author Matteo Scaramuccia <[email protected]> |
|
15 | + * @copyright 2013-2015 phpMyFAQ Team |
|
16 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
17 | + * @link http://www.phpmyfaq.de |
|
18 | + * @since 2013-01-02 |
|
19 | + */ |
|
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
@@ -20,10 +20,10 @@ |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 |
@@ -1,21 +1,21 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * AJAX: handling of Ajax group calls |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Thorsten Rinne <[email protected]> |
|
14 | - * @copyright 2009-2015 phpMyFAQ Team |
|
15 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
16 | - * @link http://www.phpmyfaq.de |
|
17 | - * @since 2009-04-06 |
|
18 | - */ |
|
3 | + * AJAX: handling of Ajax group calls |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Thorsten Rinne <[email protected]> |
|
14 | + * @copyright 2009-2015 phpMyFAQ Team |
|
15 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
16 | + * @link http://www.phpmyfaq.de |
|
17 | + * @since 2009-04-06 |
|
18 | + */ |
|
19 | 19 | |
20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
21 | 21 | $protocol = 'http'; |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | |
56 | 56 | // Return the group rights |
57 | 57 | if ('get_group_rights' == $ajaxAction) { |
58 | - echo json_encode($user->perm->getGroupRights($groupId)); |
|
58 | + echo json_encode($user->perm->getGroupRights($groupId)); |
|
59 | 59 | } |
60 | 60 | |
61 | 61 | // Return all users |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | foreach ($userList as $single_user) { |
65 | 65 | $user->getUserById($single_user, true); |
66 | 66 | $users[] = array('user_id' => $user->getUserId(), |
67 | - 'login' => $user->getLogin()); |
|
67 | + 'login' => $user->getLogin()); |
|
68 | 68 | } |
69 | 69 | echo json_encode($users); |
70 | 70 | } |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | foreach ($memberList as $single_member) { |
77 | 77 | $user->getUserById($single_member, true); |
78 | 78 | $members[] = array('user_id' => $user->getUserId(), |
79 | - 'login' => $user->getLogin()); |
|
79 | + 'login' => $user->getLogin()); |
|
80 | 80 | } |
81 | 81 | echo json_encode($members); |
82 | 82 | } |
@@ -20,10 +20,10 @@ |
||
20 | 20 | |
21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
22 | 22 | $protocol = 'http'; |
23 | - if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON'){ |
|
23 | + if (isset($_SERVER['HTTPS']) && strtoupper($_SERVER['HTTPS']) === 'ON') { |
|
24 | 24 | $protocol = 'https'; |
25 | 25 | } |
26 | - header('Location: ' . $protocol . '://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['SCRIPT_NAME'])); |
|
26 | + header('Location: '.$protocol.'://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['SCRIPT_NAME'])); |
|
27 | 27 | exit(); |
28 | 28 | } |
29 | 29 |
@@ -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 | |
@@ -35,11 +35,11 @@ discard block |
||
35 | 35 | 'filter' => FILTER_VALIDATE_INT, |
36 | 36 | 'flags' => FILTER_REQUIRE_ARRAY |
37 | 37 | ); |
38 | - $checkNews = array( |
|
38 | + $checkNews = array( |
|
39 | 39 | 'filter' => FILTER_VALIDATE_INT, |
40 | 40 | 'flags' => FILTER_REQUIRE_ARRAY |
41 | 41 | ); |
42 | - $ret = false; |
|
42 | + $ret = false; |
|
43 | 43 | |
44 | 44 | $faqComments = PMF_Filter::filterInputArray(INPUT_POST, array('faq_comments' => $checkFaqs)); |
45 | 45 | $newsComments = PMF_Filter::filterInputArray(INPUT_POST, array('news_comments' => $checkNews)); |
@@ -1,21 +1,21 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * AJAX: deletes comments with the given id |
|
4 | - * |
|
5 | - * PHP Version 5.3 |
|
6 | - * |
|
7 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | - * |
|
11 | - * @category phpMyFAQ |
|
12 | - * @package Administration |
|
13 | - * @author Thorsten Rinne <[email protected]> |
|
14 | - * @copyright 2009-2015 phpMyFAQ Team |
|
15 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
16 | - * @link http://www.phpmyfaq.de |
|
17 | - * @since 2009-03-20 |
|
18 | - */ |
|
3 | + * AJAX: deletes comments with the given id |
|
4 | + * |
|
5 | + * PHP Version 5.3 |
|
6 | + * |
|
7 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
8 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
9 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
10 | + * |
|
11 | + * @category phpMyFAQ |
|
12 | + * @package Administration |
|
13 | + * @author Thorsten Rinne <[email protected]> |
|
14 | + * @copyright 2009-2015 phpMyFAQ Team |
|
15 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
16 | + * @link http://www.phpmyfaq.de |
|
17 | + * @since 2009-03-20 |
|
18 | + */ |
|
19 | 19 | |
20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
21 | 21 | $protocol = 'http'; |