Ignore:
Timestamp:
08/27/10 23:01:58 (21 months ago)
Author:
vain
Message:
  • minor change to all security constant checks
  • fixed the non rewrite routing
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/modules/users/controller/users.admin.php

    r4506 r4599  
    2222    * 
    2323    * @license    GNU/GPL v2 or (at your option) any later version, see "/doc/LICENSE". 
    24     * 
    2524    * @author     Jens-André Koch <vain@clansuite.com> 
    2625    * @copyright  Copyleft: All rights reserved. Jens-André Koch (2005-onwards) 
    27     * 
    2826    * @link       http://www.clansuite.com 
    29     * @link       http://gna.org/projects/clansuite 
    3027    * 
    3128    * @version    SVN: $Id: menueditor.module.php 2095 2008-06-11 23:44:20Z vain $ 
     
    3330 
    3431//Security Handler 
    35 if(defined('IN_CS') == false) 
     32if(defined('IN_CS') === false) 
    3633{ 
    3734    die('Clansuite not loaded. Direct Access forbidden.'); 
     
    4542 * @subpackage  Users 
    4643*/ 
    47 class Clansuite_Module_Users_Admin extends Clansuite_Module_Controller implements Clansuite_Module_Interface 
     44class Clansuite_Module_Users_Admin extends Clansuite_Module_Controller 
    4845{ 
    49     public function initializeModule(Clansuite_HttpRequest $request, Clansuite_HttpResponse $response) 
     46    public function initializeModule() 
    5047    { 
    5148        parent::initModel('users'); 
     
    7572 
    7673        // SmartyColumnSort -- Easy sorting of html table columns. 
    77         include ROOT_LIBRARIES . '/smarty/libs/SmartyColumnSort.class.php'); 
     74        include ROOT_LIBRARIES . '/smarty/libs/SmartyColumnSort.class.php'; 
    7875        // A list of database columns to use in the table. 
    7976        $columns = array( 'u.user_id', 'u.nick', 'u.email', 'u.timestamp', 'u.joined'); 
     
    199196        $this->redirect( 'index.php?mod=users&sub=admin&action=show_all', 3, _( 'The selected user(s) were deleted.' )); 
    200197    } 
    201      
     198 
    202199    /** 
    203200     * Action for displaying the Settings of a Module Users 
     
    207204        # Set Pagetitle and Breadcrumbs 
    208205        Clansuite_Breadcrumb::add( _('Settings'), '/index.php?mod=users&amp;sub=admin&amp;action=settings'); 
    209          
     206 
    210207        $settings = array(); 
    211          
     208 
    212209        $settings['form']   = array(    'name' => 'users_settings', 
    213210                                        'method' => 'POST', 
    214211                                        'action' => WWW_ROOT.'/index.php?mod=users&amp;sub=admin&amp;action=settings_update'); 
    215                                          
     212 
    216213        $settings['users'][] = array(   'id' => 'items_lastregisteredusers', 
    217214                                        'name' => 'items_lastregisteredusers', 
     
    220217                                        'formfieldtype' => 'text', 
    221218                                        'value' => $this->getConfigValue('items_lastregisteredusers', '4')); 
    222         
     219 
    223220        include ROOT_CORE . '/viewhelper/formgenerator.core.php'; 
    224221        $form = new Clansuite_Array_Formgenerator($settings); 
    225          
     222 
    226223        $form->addElement('submitbutton')->setName('Save'); 
    227224        $form->addElement('resetbutton'); 
    228          
     225 
    229226        # assign the html of the form to the view 
    230227        $this->getView()->assign('form', $form->render()); 
    231228 
    232         $this->display();        
    233     } 
    234      
     229        $this->display(); 
     230    } 
     231 
    235232    public function action_admin_settings_update() 
    236     {  
     233    { 
    237234        # Set Pagetitle and Breadcrumbs 
    238235        Clansuite_Breadcrumb::add( _('Update'), '/index.php?mod=users&amp;sub=settings&amp;action=update'); 
     
    242239 
    243240        # Get Configuration from Injector 
    244         $config = $this->injector->instantiate('Clansuite_Config'); 
    245          
     241        $config = $this->getInjector()->instantiate('Clansuite_Config'); 
     242 
    246243        # write config 
    247244        $config->confighandler->writeConfig( ROOT_MOD . 'users/users.config.php', $data); 
Note: See TracChangeset for help on using the changeset viewer.