@@ -1,22 +1,22 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Displays the group management frontend |
|
| 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 Lars Tiedemann <[email protected]> |
|
| 14 | - * @author Thorsten Rinne <[email protected]> |
|
| 15 | - * @copyright 2005-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 2005-12-15 |
|
| 19 | - */ |
|
| 3 | + * Displays the group management frontend |
|
| 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 Lars Tiedemann <[email protected]> |
|
| 14 | + * @author Thorsten Rinne <[email protected]> |
|
| 15 | + * @copyright 2005-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 2005-12-15 |
|
| 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 | |
@@ -222,7 +222,7 @@ discard block |
||
| 222 | 222 | $groupAction = 'add'; |
| 223 | 223 | $message = '<p class="alert alert-error">'; |
| 224 | 224 | foreach ($messages as $err) { |
| 225 | - $message .= $err . '<br />'; |
|
| 225 | + $message .= $err.'<br />'; |
|
| 226 | 226 | } |
| 227 | 227 | $message .= '</p>'; |
| 228 | 228 | } |
@@ -210,8 +210,9 @@ discard block |
||
| 210 | 210 | 'auto_join' => $group_auto_join |
| 211 | 211 | ); |
| 212 | 212 | |
| 213 | - if ($user->perm->addGroup($group_data) <= 0) |
|
| 214 | - $messages[] = $PMF_LANG['ad_adus_dberr']; |
|
| 213 | + if ($user->perm->addGroup($group_data) <= 0) { |
|
| 214 | + $messages[] = $PMF_LANG['ad_adus_dberr']; |
|
| 215 | + } |
|
| 215 | 216 | } |
| 216 | 217 | // no errors, show list |
| 217 | 218 | if (count($messages) == 0) { |
@@ -228,8 +229,9 @@ discard block |
||
| 228 | 229 | } |
| 229 | 230 | } |
| 230 | 231 | |
| 231 | -if (!isset($message)) |
|
| 232 | +if (!isset($message)) { |
|
| 232 | 233 | $message = ''; |
| 234 | +} |
|
| 233 | 235 | |
| 234 | 236 | // show new group form |
| 235 | 237 | if ($groupAction == 'add' && $permission['addgroup']) { |
@@ -1,21 +1,21 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Frontend for Backup and Restore |
|
| 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-02-24 |
|
| 18 | - */ |
|
| 3 | + * Frontend for Backup and Restore |
|
| 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-02-24 |
|
| 18 | + */ |
|
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $protocol = 'http'; |
@@ -59,5 +59,5 @@ discard block |
||
| 59 | 59 | </form> |
| 60 | 60 | <?php |
| 61 | 61 | } else { |
| 62 | - print $PMF_LANG["err_NotAuth"]; |
|
| 62 | + print $PMF_LANG["err_NotAuth"]; |
|
| 63 | 63 | } |
@@ -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 | - * Adds a record in the database, handles the preview and checks for missing |
|
| 4 | - * category entries. |
|
| 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-02-23 |
|
| 19 | - */ |
|
| 3 | + * Adds a record in the database, handles the preview and checks for missing |
|
| 4 | + * category entries. |
|
| 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-02-23 |
|
| 19 | + */ |
|
| 20 | 20 | |
| 21 | 21 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 22 | 22 | $protocol = 'http'; |
@@ -20,14 +20,14 @@ 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 | -if ($permission['editbt']|| $permission['addbt']) { |
|
| 30 | +if ($permission['editbt'] || $permission['addbt']) { |
|
| 31 | 31 | |
| 32 | 32 | // FAQ data |
| 33 | 33 | $dateStart = PMF_Filter::filterInput(INPUT_POST, 'dateStart', FILTER_SANITIZE_STRING); |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | $category->setGroups($currentAdminGroups); |
| 107 | 107 | $tagging = new PMF_Tags($faqConfig); |
| 108 | 108 | |
| 109 | - $recordData = array( |
|
| 109 | + $recordData = array( |
|
| 110 | 110 | 'lang' => $recordLang, |
| 111 | 111 | 'active' => $active, |
| 112 | 112 | 'sticky' => (!is_null($sticky) ? 1 : 0), |
@@ -117,8 +117,8 @@ discard block |
||
| 117 | 117 | 'email' => $email, |
| 118 | 118 | 'comment' => (!is_null($comment) ? 'y' : 'n'), |
| 119 | 119 | 'date' => date('YmdHis'), |
| 120 | - 'dateStart' => (empty($dateStart) ? '00000000000000' : str_replace('-', '', $dateStart) . '000000'), |
|
| 121 | - 'dateEnd' => (empty($dateEnd) ? '99991231235959' : str_replace('-', '', $dateEnd) . '235959'), |
|
| 120 | + 'dateStart' => (empty($dateStart) ? '00000000000000' : str_replace('-', '', $dateStart).'000000'), |
|
| 121 | + 'dateEnd' => (empty($dateEnd) ? '99991231235959' : str_replace('-', '', $dateEnd).'235959'), |
|
| 122 | 122 | 'linkState' => '', |
| 123 | 123 | 'linkDateCheck' => 0 |
| 124 | 124 | ); |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | $faq->updateQuestionAnswer($openQuestionId, $recordId, $categories['rubrik'][0]); |
| 163 | 163 | } |
| 164 | 164 | |
| 165 | - $url = sprintf( |
|
| 165 | + $url = sprintf( |
|
| 166 | 166 | '%s?action=artikel&cat=%d&id=%d&artlang=%s', |
| 167 | 167 | $faqConfig->get('main.referenceURL'), |
| 168 | 168 | $categories['rubrik'][0], |
@@ -194,14 +194,14 @@ discard block |
||
| 194 | 194 | $faqConfig->get('socialnetworks.twitterAccessTokenSecret') |
| 195 | 195 | ); |
| 196 | 196 | |
| 197 | - $link = PMF_Link::getSystemRelativeUri() . |
|
| 197 | + $link = PMF_Link::getSystemRelativeUri(). |
|
| 198 | 198 | sprintf( |
| 199 | 199 | '?action=artikel&cat=%d&id=%d&artlang=%s', |
| 200 | 200 | $category, |
| 201 | 201 | $recordId, |
| 202 | 202 | $recordLang |
| 203 | 203 | ); |
| 204 | - $link = $faqConfig->get('main.referenceURL') . str_replace('/admin/','/', $link); |
|
| 204 | + $link = $faqConfig->get('main.referenceURL').str_replace('/admin/', '/', $link); |
|
| 205 | 205 | $oLink = new PMF_Link($link, $faqConfig); |
| 206 | 206 | $oLink->itemTitle = $question; |
| 207 | 207 | $link = $oLink->toString(); |
@@ -227,7 +227,7 @@ discard block |
||
| 227 | 227 | } else { |
| 228 | 228 | printf( |
| 229 | 229 | '<p class="alert alert-error">%s</p>', |
| 230 | - $PMF_LANG['ad_entry_savedfail'] . $faqConfig->getDb()->error() |
|
| 230 | + $PMF_LANG['ad_entry_savedfail'].$faqConfig->getDb()->error() |
|
| 231 | 231 | ); |
| 232 | 232 | } |
| 233 | 233 | |
@@ -1,30 +1,30 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * AJAX: onDemandURL |
|
| 4 | - * |
|
| 5 | - * Usage: |
|
| 6 | - * index.php?action=ajax&ajax=onDemandURL&id=<id>&artlang=<lang>[&lookup=1] |
|
| 7 | - * |
|
| 8 | - * Performs link verification at demand of the user. |
|
| 9 | - * |
|
| 10 | - * PHP Version 5.3 |
|
| 11 | - * |
|
| 12 | - * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
| 13 | - * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
| 14 | - * obtain one at http://mozilla.org/MPL/2.0/. |
|
| 15 | - * |
|
| 16 | - * The Initial Developer of the Original Code is released for external use |
|
| 17 | - * with permission from NetJapan, Inc. IT Administration Group. |
|
| 18 | - * |
|
| 19 | - * @category phpMyFAQ |
|
| 20 | - * @package Administration |
|
| 21 | - * @author Minoru TODA <[email protected]> |
|
| 22 | - * @author Thorsten Rinne <[email protected]> |
|
| 23 | - * @copyright 2005-2015 NetJapan, Inc. |
|
| 24 | - * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
| 25 | - * @link http://www.phpmyfaq.de |
|
| 26 | - * @since 2005-09-30 |
|
| 27 | - */ |
|
| 3 | + * AJAX: onDemandURL |
|
| 4 | + * |
|
| 5 | + * Usage: |
|
| 6 | + * index.php?action=ajax&ajax=onDemandURL&id=<id>&artlang=<lang>[&lookup=1] |
|
| 7 | + * |
|
| 8 | + * Performs link verification at demand of the user. |
|
| 9 | + * |
|
| 10 | + * PHP Version 5.3 |
|
| 11 | + * |
|
| 12 | + * This Source Code Form is subject to the terms of the Mozilla Public License, |
|
| 13 | + * v. 2.0. If a copy of the MPL was not distributed with this file, You can |
|
| 14 | + * obtain one at http://mozilla.org/MPL/2.0/. |
|
| 15 | + * |
|
| 16 | + * The Initial Developer of the Original Code is released for external use |
|
| 17 | + * with permission from NetJapan, Inc. IT Administration Group. |
|
| 18 | + * |
|
| 19 | + * @category phpMyFAQ |
|
| 20 | + * @package Administration |
|
| 21 | + * @author Minoru TODA <[email protected]> |
|
| 22 | + * @author Thorsten Rinne <[email protected]> |
|
| 23 | + * @copyright 2005-2015 NetJapan, Inc. |
|
| 24 | + * @license http://www.mozilla.org/MPL/2.0/ Mozilla Public License Version 2.0 |
|
| 25 | + * @link http://www.phpmyfaq.de |
|
| 26 | + * @since 2005-09-30 |
|
| 27 | + */ |
|
| 28 | 28 | |
| 29 | 29 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 30 | 30 | $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 | |
@@ -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 | |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | if (!is_null($question) && !is_null($categories)) { |
| 110 | 110 | // Save entry |
| 111 | 111 | $logging = new PMF_Logging($faqConfig); |
| 112 | - $logging->logAdmin($user, 'Beitragsave ' . $recordId); |
|
| 112 | + $logging->logAdmin($user, 'Beitragsave '.$recordId); |
|
| 113 | 113 | |
| 114 | 114 | printf( |
| 115 | 115 | '<header><h2><i class="icon-pencil"></i> %s</h2></header>', |
@@ -137,8 +137,8 @@ discard block |
||
| 137 | 137 | 'email' => $email, |
| 138 | 138 | 'comment' => (!is_null($comment) ? 'y' : 'n'), |
| 139 | 139 | 'date' => empty($date) ? date('YmdHis') : str_replace(array('-', ':', ' '), '', $date), |
| 140 | - 'dateStart' => (empty($dateStart) ? '00000000000000' : str_replace('-', '', $dateStart) . '000000'), |
|
| 141 | - 'dateEnd' => (empty($dateEnd) ? '99991231235959' : str_replace('-', '', $dateEnd) . '235959'), |
|
| 140 | + 'dateStart' => (empty($dateStart) ? '00000000000000' : str_replace('-', '', $dateStart).'000000'), |
|
| 141 | + 'dateEnd' => (empty($dateEnd) ? '99991231235959' : str_replace('-', '', $dateEnd).'235959'), |
|
| 142 | 142 | 'linkState' => '', |
| 143 | 143 | 'linkDateCheck' => 0); |
| 144 | 144 | |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | } else { |
| 163 | 163 | printf( |
| 164 | 164 | '<p class="alert alert-error">%s</p>', |
| 165 | - print $PMF_LANG['ad_entry_savedfail'] . $faqConfig->getDb()->error() |
|
| 165 | + print $PMF_LANG['ad_entry_savedfail'].$faqConfig->getDb()->error() |
|
| 166 | 166 | ); |
| 167 | 167 | } |
| 168 | 168 | |
@@ -1,22 +1,22 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * The start page with some information about the FAQ |
|
| 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 Alexander M. Turek <[email protected]> |
|
| 15 | - * @copyright 2005-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-02-05 |
|
| 19 | - */ |
|
| 3 | + * The start page with some information about the FAQ |
|
| 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 Alexander M. Turek <[email protected]> |
|
| 15 | + * @copyright 2005-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-02-05 |
|
| 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 | |
@@ -53,23 +53,23 @@ discard block |
||
| 53 | 53 | </div> |
| 54 | 54 | <div class="dashboard-stat span2"> |
| 55 | 55 | <span><a href="?action=view"><?php echo $PMF_LANG["ad_start_articles"]; ?></a></span> |
| 56 | - <?php echo $faqTableInfo[PMF_Db::getTablePrefix() . "faqdata"]; ?> |
|
| 56 | + <?php echo $faqTableInfo[PMF_Db::getTablePrefix()."faqdata"]; ?> |
|
| 57 | 57 | </div> |
| 58 | 58 | <div class="dashboard-stat span2"> |
| 59 | 59 | <span><a href="?action=comments"><?php echo $PMF_LANG["ad_start_comments"]; ?></a></span> |
| 60 | - <?php echo $faqTableInfo[PMF_Db::getTablePrefix() . "faqcomments"]; ?> |
|
| 60 | + <?php echo $faqTableInfo[PMF_Db::getTablePrefix()."faqcomments"]; ?> |
|
| 61 | 61 | </div> |
| 62 | 62 | <div class="dashboard-stat span2"> |
| 63 | 63 | <span><a href="?action=question"><?php echo $PMF_LANG["msgOpenQuestions"]; ?></a></span> |
| 64 | - <?php echo $faqTableInfo[PMF_Db::getTablePrefix() . "faqquestions"]; ?> |
|
| 64 | + <?php echo $faqTableInfo[PMF_Db::getTablePrefix()."faqquestions"]; ?> |
|
| 65 | 65 | </div> |
| 66 | 66 | <div class="dashboard-stat span2"> |
| 67 | 67 | <span><a href="?action=news"><?php echo $PMF_LANG["msgNews"]; ?></a></span> |
| 68 | - <?php echo $faqTableInfo[PMF_Db::getTablePrefix() . "faqnews"]; ?> |
|
| 68 | + <?php echo $faqTableInfo[PMF_Db::getTablePrefix()."faqnews"]; ?> |
|
| 69 | 69 | </div> |
| 70 | 70 | <div class="dashboard-stat span2"> |
| 71 | 71 | <span><a href="?action=user&user_action=listallusers"><?php echo $PMF_LANG['admin_mainmenu_users']; ?></a></span> |
| 72 | - <?php echo $faqTableInfo[PMF_Db::getTablePrefix() . 'faquser'] - 1; ?> |
|
| 72 | + <?php echo $faqTableInfo[PMF_Db::getTablePrefix().'faquser'] - 1; ?> |
|
| 73 | 73 | </div> |
| 74 | 74 | </section> |
| 75 | 75 | |
@@ -126,7 +126,7 @@ discard block |
||
| 126 | 126 | ); |
| 127 | 127 | // Installed phpMyFAQ version is outdated |
| 128 | 128 | if (-1 == version_compare($installed, $available)) { |
| 129 | - print '<br />' . $PMF_LANG['ad_you_should_update']; |
|
| 129 | + print '<br />'.$PMF_LANG['ad_you_should_update']; |
|
| 130 | 130 | } |
| 131 | 131 | } |
| 132 | 132 | } else { |
@@ -155,7 +155,7 @@ discard block |
||
| 155 | 155 | $faqSystem = new PMF_System(); |
| 156 | 156 | $localHashes = $faqSystem->createHashes(); |
| 157 | 157 | $remoteHashes = file_get_contents( |
| 158 | - 'http://api.phpmyfaq.de/verify/' . $faqConfig->get('main.currentVersion') |
|
| 158 | + 'http://api.phpmyfaq.de/verify/'.$faqConfig->get('main.currentVersion') |
|
| 159 | 159 | ); |
| 160 | 160 | |
| 161 | 161 | if (!is_array(json_decode($remoteHashes, true))) { |
@@ -37,8 +37,11 @@ |
||
| 37 | 37 | <a href="?action=config"> |
| 38 | 38 | <?php if ($faqConfig->get('main.maintenanceMode')): ?> |
| 39 | 39 | <span class="label label-important"><?php print $PMF_LANG['msgMaintenanceMode']; ?></span> |
| 40 | - <?php else: ?> |
|
| 41 | - <span class="label label-success"><?php print $PMF_LANG['msgOnlineMode']; ?></span> |
|
| 40 | + <?php else { |
|
| 41 | + : ?> |
|
| 42 | + <span class="label label-success"><?php print $PMF_LANG['msgOnlineMode']; |
|
| 43 | +} |
|
| 44 | +?></span> |
|
| 42 | 45 | <?php endif; ?> |
| 43 | 46 | </a> |
| 44 | 47 | </div> |
@@ -1,21 +1,21 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Read in files for the translation and show them inside a form. |
|
| 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 Anatoliy Belsky <[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-05-11 |
|
| 18 | - */ |
|
| 3 | + * Read in files for the translation and show them inside a form. |
|
| 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 Anatoliy Belsky <[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-05-11 |
|
| 18 | + */ |
|
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $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 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Delete open questions |
|
| 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-02-24 |
|
| 18 | - */ |
|
| 3 | + * Delete open questions |
|
| 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-02-24 |
|
| 18 | + */ |
|
| 19 | 19 | |
| 20 | 20 | if (!defined('IS_VALID_PHPMYFAQ')) { |
| 21 | 21 | $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 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * AJAX: Search for tags |
|
| 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 Ajax |
|
| 13 | - * @author Matteo Scaramuccia <[email protected]> |
|
| 14 | - * @copyright 2005-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 2005-12-15 |
|
| 18 | - */ |
|
| 3 | + * AJAX: Search for tags |
|
| 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 Ajax |
|
| 13 | + * @author Matteo Scaramuccia <[email protected]> |
|
| 14 | + * @copyright 2005-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 2005-12-15 |
|
| 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 | |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | |
| 34 | 34 | $oTag = new PMF_Tags($faqConfig); |
| 35 | 35 | $autoCompleteValue = PMF_Filter::filterInput(INPUT_GET, 'q', FILTER_SANITIZE_STRIPPED); |
| 36 | -if (! is_null($autoCompleteValue)) { |
|
| 36 | +if (!is_null($autoCompleteValue)) { |
|
| 37 | 37 | if (strpos($autoCompleteValue, ',')) { |
| 38 | 38 | $arrayOfValues = explode(',', $autoCompleteValue); |
| 39 | 39 | $autoCompleteValue = end($arrayOfValues); |