@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | public function DeleteByIds($links_ids) |
| 107 | 107 | { |
| 108 | 108 | $criteria = new CriteriaCompo(); |
| 109 | - $criteria->add(new Criteria('link_id', '(' . implode(', ', $links_ids) . ')', 'IN')); |
|
| 109 | + $criteria->add(new Criteria('link_id', '('.implode(', ', $links_ids).')', 'IN')); |
|
| 110 | 110 | return parent::deleteAll($criteria); |
| 111 | 111 | } |
| 112 | 112 | |
@@ -124,13 +124,13 @@ discard block |
||
| 124 | 124 | $keys = array_keys($ret['related_links']); |
| 125 | 125 | foreach ($keys as $k => $i) { |
| 126 | 126 | if ($content_id == $ret['related_links'][$i]['content_id']) { |
| 127 | - if (($k-1) >= 0) { |
|
| 128 | - $ret['prev_id'] = $ret['related_links'][$keys[($k-1)]]['content_id']; |
|
| 129 | - $ret['prev_title'] = $ret['related_links'][$keys[($k-1)]]['content_title']; |
|
| 127 | + if (($k - 1) >= 0) { |
|
| 128 | + $ret['prev_id'] = $ret['related_links'][$keys[($k - 1)]]['content_id']; |
|
| 129 | + $ret['prev_title'] = $ret['related_links'][$keys[($k - 1)]]['content_title']; |
|
| 130 | 130 | } |
| 131 | - if (($k+1) < count($keys)) { |
|
| 132 | - $ret['next_id'] = $ret['related_links'][$keys[($k+1)]]['content_id']; |
|
| 133 | - $ret['next_title'] = $ret['related_links'][$keys[($k+1)]]['content_title']; |
|
| 131 | + if (($k + 1) < count($keys)) { |
|
| 132 | + $ret['next_id'] = $ret['related_links'][$keys[($k + 1)]]['content_id']; |
|
| 133 | + $ret['next_title'] = $ret['related_links'][$keys[($k + 1)]]['content_title']; |
|
| 134 | 134 | } |
| 135 | 135 | break; |
| 136 | 136 | } |
@@ -55,7 +55,7 @@ |
||
| 55 | 55 | $criteria->add(new Criteria('gperm_itemid', $content_id)); |
| 56 | 56 | $criteria->add(new Criteria('gperm_modid', $module_id)); |
| 57 | 57 | $criteria->add(new Criteria('gperm_name', 'page_view_item', '=')); |
| 58 | - $criteria->add(new Criteria('gperm_groupid', '(' . implode(', ', $groups_delete) . ')', 'IN')); |
|
| 58 | + $criteria->add(new Criteria('gperm_groupid', '('.implode(', ', $groups_delete).')', 'IN')); |
|
| 59 | 59 | if (parent::deleteAll($criteria)) { |
| 60 | 60 | } |
| 61 | 61 | } |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | public function getValues($keys = null, $format = null, $maxDepth = null) |
| 41 | 41 | { |
| 42 | 42 | $ret = parent::getValues($keys, $format, $maxDepth); |
| 43 | - $ret['navigation'] = \Xoops\Locale::translate('L_RELATED_NAVIGATION_OPTION' . $this->getVar('related_navigation'), 'page'); |
|
| 43 | + $ret['navigation'] = \Xoops\Locale::translate('L_RELATED_NAVIGATION_OPTION'.$this->getVar('related_navigation'), 'page'); |
|
| 44 | 44 | $ret['related_links'] = Page::getInstance()->getLinkHandler()->getLinks($this->getVar('related_id')); |
| 45 | 45 | return $ret; |
| 46 | 46 | } |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | //title |
| 51 | 51 | $tab1->addElement(new Xoops\Form\Text(XoopsLocale::TITLE, 'content_title', 12, 255, $obj->getVar('content_title'), ''), true); |
| 52 | 52 | // editor |
| 53 | - $editor_configs=array(); |
|
| 53 | + $editor_configs = array(); |
|
| 54 | 54 | $editor_configs['editor'] = $helper->getConfig('page_editor'); |
| 55 | 55 | $editor_configs['rows'] = 12; |
| 56 | 56 | $editor_configs['cols'] = 12; |
@@ -94,7 +94,7 @@ discard block |
||
| 94 | 94 | $checkbox = new Xoops\Form\Checkbox(XoopsLocale::OPTIONS, 'content_option', $content_option, false); |
| 95 | 95 | $checkbox->setDescription(PageLocale::CONTENT_OPTIONS_DSC); |
| 96 | 96 | foreach ($obj->options as $option) { |
| 97 | - $checkbox->addOption($option, \Xoops\Locale::translate('L_CONTENT_DO' . strtoupper($option), 'page')); |
|
| 97 | + $checkbox->addOption($option, \Xoops\Locale::translate('L_CONTENT_DO'.strtoupper($option), 'page')); |
|
| 98 | 98 | } |
| 99 | 99 | $tab3->addElement($checkbox); |
| 100 | 100 | //maindisplay |
@@ -64,7 +64,7 @@ |
||
| 64 | 64 | |
| 65 | 65 | // Metas |
| 66 | 66 | //description |
| 67 | -$xoTheme->addMeta('meta', 'description', strip_tags($helper->getModule()->name()) . ', ' . implode(',', $keywords)); |
|
| 67 | +$xoTheme->addMeta('meta', 'description', strip_tags($helper->getModule()->name()).', '.implode(',', $keywords)); |
|
| 68 | 68 | //keywords |
| 69 | 69 | $xoTheme->addMeta('meta', 'keywords', implode(',', $keywords)); |
| 70 | 70 | unset($keywords); |
@@ -24,18 +24,18 @@ |
||
| 24 | 24 | |
| 25 | 25 | static $xcaptcha_handler; |
| 26 | 26 | if (!isset($xcaptcha_handler)) { |
| 27 | - include_once dirname(__DIR__) . '/class/xcaptcha.php'; |
|
| 27 | + include_once dirname(__DIR__).'/class/xcaptcha.php'; |
|
| 28 | 28 | $xcaptcha_handler = new Xcaptcha(); |
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | $xoops = Xoops::getInstance(); |
| 32 | 32 | |
| 33 | -foreach ( array_keys($xcaptcha_handler->getPluginList()) as $key ) { |
|
| 33 | +foreach (array_keys($xcaptcha_handler->getPluginList()) as $key) { |
|
| 34 | 34 | ++$cpt; |
| 35 | 35 | $xoops->loadLanguage($key, 'xcaptcha'); |
| 36 | 36 | |
| 37 | - $adminmenu[$cpt]['title'] = constant('_MI_XCAPTCHA_ADMENU_' . strtoupper($key) ); |
|
| 38 | - $adminmenu[$cpt]['link'] = 'admin/index.php?type=' . $key; |
|
| 37 | + $adminmenu[$cpt]['title'] = constant('_MI_XCAPTCHA_ADMENU_'.strtoupper($key)); |
|
| 38 | + $adminmenu[$cpt]['link'] = 'admin/index.php?type='.$key; |
|
| 39 | 39 | $adminmenu[$cpt]['icon'] = 'administration.png'; |
| 40 | 40 | } |
| 41 | 41 | |
@@ -16,7 +16,7 @@ discard block |
||
| 16 | 16 | * @version $Id$ |
| 17 | 17 | */ |
| 18 | 18 | |
| 19 | -include __DIR__ . '/header.php'; |
|
| 19 | +include __DIR__.'/header.php'; |
|
| 20 | 20 | |
| 21 | 21 | $xoops = Xoops::getInstance(); |
| 22 | 22 | |
@@ -32,8 +32,8 @@ discard block |
||
| 32 | 32 | } else { |
| 33 | 33 | if ($xcaptcha_handler->loadPluginHandler($type)) { |
| 34 | 34 | $config = $xcaptcha_handler->Pluginhandler->VerifyData(); |
| 35 | - $xcaptcha_handler->writeConfig('captcha.config.' . $type, $config); |
|
| 36 | - $xoops->redirect('index.php?type=' . $type, 5, _AM_XCAPTCHA_SAVED); |
|
| 35 | + $xcaptcha_handler->writeConfig('captcha.config.'.$type, $config); |
|
| 36 | + $xoops->redirect('index.php?type='.$type, 5, _AM_XCAPTCHA_SAVED); |
|
| 37 | 37 | } |
| 38 | 38 | } |
| 39 | 39 | break; |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | $admin_page->addInfoBoxLine($form->render()); |
| 54 | 54 | } else { |
| 55 | 55 | if ($plugin = $xcaptcha_handler->loadPluginHandler($type)) { |
| 56 | - $title = constant('_XCAPTCHA_FORM_' . strtoupper($type)); |
|
| 56 | + $title = constant('_XCAPTCHA_FORM_'.strtoupper($type)); |
|
| 57 | 57 | $form = $xoops->getModuleForm($plugin, $type, 'xcaptcha'); |
| 58 | 58 | $admin_page->addInfoBox($title); |
| 59 | 59 | $admin_page->addInfoBoxLine($form->render()); |
@@ -65,4 +65,4 @@ discard block |
||
| 65 | 65 | |
| 66 | 66 | break; |
| 67 | 67 | } |
| 68 | -include __DIR__ . '/footer.php'; |
|
| 68 | +include __DIR__.'/footer.php'; |
|
@@ -17,16 +17,16 @@ discard block |
||
| 17 | 17 | * @version $Id$ |
| 18 | 18 | */ |
| 19 | 19 | |
| 20 | -require_once dirname(dirname(dirname(__DIR__))) . '/include/cp_header.php'; |
|
| 20 | +require_once dirname(dirname(dirname(__DIR__))).'/include/cp_header.php'; |
|
| 21 | 21 | |
| 22 | 22 | $op = ''; |
| 23 | -if ( isset( $_POST ) ){ |
|
| 24 | - foreach ( $_POST as $k => $v ) { |
|
| 23 | +if (isset($_POST)) { |
|
| 24 | + foreach ($_POST as $k => $v) { |
|
| 25 | 25 | ${$k} = $v; |
| 26 | 26 | } |
| 27 | 27 | } |
| 28 | -if ( isset( $_GET ) ){ |
|
| 29 | - foreach ( $_GET as $k => $v ) { |
|
| 28 | +if (isset($_GET)) { |
|
| 29 | + foreach ($_GET as $k => $v) { |
|
| 30 | 30 | ${$k} = $v; |
| 31 | 31 | } |
| 32 | 32 | } |
@@ -36,5 +36,5 @@ discard block |
||
| 36 | 36 | $xoops = Xoops::getInstance(); |
| 37 | 37 | $system = System::getInstance(); |
| 38 | 38 | |
| 39 | -include_once dirname(__DIR__) . '/class/xcaptcha.php'; |
|
| 39 | +include_once dirname(__DIR__).'/class/xcaptcha.php'; |
|
| 40 | 40 | $xcaptcha_handler = new Xcaptcha(); |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | $this->config = $this->loadConfig(); |
| 35 | 35 | $this->plugin_List = $this->getPluginList(); |
| 36 | 36 | $this->plugin_config = $this->loadConfigPlugin(); |
| 37 | - $this->xcaptcha_path_plugin = \XoopsBaseConfig::get('root-path') . '/modules/xcaptcha/plugins'; |
|
| 37 | + $this->xcaptcha_path_plugin = \XoopsBaseConfig::get('root-path').'/modules/xcaptcha/plugins'; |
|
| 38 | 38 | } |
| 39 | 39 | |
| 40 | 40 | static function getInstance() |
@@ -71,7 +71,7 @@ discard block |
||
| 71 | 71 | { |
| 72 | 72 | $ret = array(); |
| 73 | 73 | |
| 74 | - foreach (glob($this->captchaHandler->path_basic . '/config.*.php') as $filename) { |
|
| 74 | + foreach (glob($this->captchaHandler->path_basic.'/config.*.php') as $filename) { |
|
| 75 | 75 | $plugin_List = preg_replace('/(config\.)(.*)(\.php)/', '$2', basename($filename)); |
| 76 | 76 | $ret[$plugin_List] = $plugin_List; |
| 77 | 77 | } |
@@ -105,9 +105,9 @@ discard block |
||
| 105 | 105 | public function loadPluginHandler($name = null) |
| 106 | 106 | { |
| 107 | 107 | $name = empty($name) ? 'text' : $name; |
| 108 | - $class = 'Xcaptcha' . ucfirst($name); |
|
| 108 | + $class = 'Xcaptcha'.ucfirst($name); |
|
| 109 | 109 | $this->Pluginhandler = null; |
| 110 | - if (XoopsLoad::fileExists($file = $this->xcaptcha_path_plugin . '/' . $name . '.php')) { |
|
| 110 | + if (XoopsLoad::fileExists($file = $this->xcaptcha_path_plugin.'/'.$name.'.php')) { |
|
| 111 | 111 | require_once $file; |
| 112 | 112 | $this->Pluginhandler = new $class($this); |
| 113 | 113 | } |