/**
  * Show the configuration page
  *
  * @access	private
  * @return	void		[Outputs to screen]
  */
 private function _chatConfig()
 {
     //-----------------------------------------
     // Load libby-do-dah
     //-----------------------------------------
     require_once IPSLib::getAppDir('core') . '/modules_admin/tools/settings.php';
     $settings = new admin_core_tools_settings();
     $settings->makeRegistryShortcuts($this->registry);
     $settings->html = $this->registry->output->loadTemplate('cp_skin_tools', 'core');
     ipsRegistry::getClass('class_localization')->loadLanguageFile(array('admin_tools'), 'core');
     $settings->form_code = $settings->html->form_code = 'module=tools&section=settings';
     $settings->form_code_js = $settings->html->form_code_js = 'module=tools&section=settings';
     //-----------------------------------------
     // Did we reset the component?
     //-----------------------------------------
     if (!$this->settings['chat_account_no']) {
         $this->_chatSplash();
     }
     $this->request['conf_title_keyword'] = 'chat';
     $settings->return_after_save = $this->settings['base_url'] . $this->form_code . '&do=chatsettings';
     $settings->_viewSettings();
 }
 /**
  * Show the configuration page
  *
  * @access	private
  * @return	void		[Outputs to screen]
  */
 private function _chatConfig()
 {
     //-----------------------------------------
     // Load libby-do-dah
     //-----------------------------------------
     require_once IPSLib::getAppDir('core') . '/modules_admin/tools/settings.php';
     $settings = new admin_core_tools_settings();
     $settings->makeRegistryShortcuts($this->registry);
     $settings->html = $this->registry->output->loadTemplate('cp_skin_tools', 'core');
     ipsRegistry::getClass('class_localization')->loadLanguageFile(array('admin_tools'), 'core');
     $settings->form_code = $settings->html->form_code = 'module=tools&section=settings';
     $settings->form_code_js = $settings->html->form_code_js = 'module=tools&section=settings';
     //-----------------------------------------
     // Did we reset the component?
     //-----------------------------------------
     if (!$this->settings['chat04_account_no']) {
         $this->_chatSplash();
     } else {
         //-----------------------------------------
         // Update version 6 or 7
         //-----------------------------------------
         if (preg_match("#^\\d#", $this->settings['chat04_account_no'])) {
             $this->DB->update('core_sys_conf_settings', array('conf_value' => 7), "conf_key='parachat_version'");
         } else {
             $this->DB->update('core_sys_conf_settings', array('conf_value' => 6), "conf_key='parachat_version'");
         }
         $settings->settingsRebuildCache();
     }
     $this->request['conf_title_keyword'] = 'chat04';
     $settings->return_after_save = $this->settings['base_url'] . $this->form_code . '&do=chatsettings';
     $settings->_viewSettings();
 }
 /**
  * Show settings for the portal
  *
  * @access	private
  * @return	void		[Outputs to screen]
  */
 private function _portalSettings()
 {
     //-------------------------------
     // INIT
     //-------------------------------
     $pc_key = IPSText::alphanumericalClean($this->request['pc_key']);
     foreach ($this->portal_objects as $key => $data) {
         if ($key == $pc_key) {
             $file = $data['_cfg_location'];
         }
     }
     //-------------------------------
     // Check
     //-------------------------------
     if (!$pc_key or !file_exists($file)) {
         $this->registry->output->global_message = $this->lang->words['error_no_key'];
         $this->_portalList();
         return;
     }
     //-------------------------------
     // Grab config file
     //-------------------------------
     require $file;
     if (!$PORTAL_CONFIG['pc_settings_keyword']) {
         $this->registry->output->global_message = $this->lang->words['error_no_settings'];
         $this->_portalList();
         return;
     }
     //-------------------------------
     // Grab, init and load settings
     //-------------------------------
     require_once IPSLib::getAppDir('core') . '/modules_admin/tools/settings.php';
     $settings = new admin_core_tools_settings();
     $settings->makeRegistryShortcuts($this->registry);
     ipsRegistry::getClass('class_localization')->loadLanguageFile(array('admin_tools'), 'core');
     $settings->html = $this->registry->output->loadTemplate('cp_skin_tools', 'core');
     $settings->form_code = $settings->html->form_code = 'module=tools&section=settings';
     $settings->form_code_js = $settings->html->form_code_js = 'module=tools&section=settings';
     $this->request['conf_title_keyword'] = $PORTAL_CONFIG['pc_settings_keyword'];
     $settings->return_after_save = $this->settings['base_url'] . $this->form_code . '&do=portal_settings&pc_key=' . $pc_key;
     $settings->_viewSettings();
 }