Project

General

Profile

« Previous | Next » 

Revision 1823

Added by Dietmar almost 12 years ago

! update user management, now home folder only will be created
if homefolders in settings are enabledPlugin
add save & back in user modify

View differences:

add.php
142 142
            //if user is in administrator-group, get this group else just get the first one
143 143
            if($admin->is_group_match($groups_id,'1')) { $group_id = 1; $groups_id = '1'; }
144 144

  
145
            // Include the WB functions file
146
            if(!function_exists('media_filename')) { require(WB_PATH.'/framework/functions.php'); }
145
            if(defined('HOME_FOLDERS') && HOME_FOLDERS) {
146
                // Include the WB functions file
147
                if(!function_exists('media_filename')) { require(WB_PATH.'/framework/functions.php'); }
147 148

  
148
            // Remove bad characters
149
            $sHomeFolder = WB_PATH.MEDIA_DIRECTORY.'/home/'.( media_filename($username) );
150
            if ( sizeof(createFolderProtectFile( $sHomeFolder )) )
151
            {
152
            	msgQueue::add($MESSAGE['MEDIA_DIR_NOT_MADE'].' ('.basename($sHomeFolder).') ' );
149
                // Remove bad characters
150
                $sHomeFolder = WB_PATH.MEDIA_DIRECTORY.'/home/'.( media_filename($username) );
151
                if ( sizeof(createFolderProtectFile( $sHomeFolder )) )
152
                {
153
                	msgQueue::add($MESSAGE['MEDIA_DIR_NOT_MADE'].' ('.basename($sHomeFolder).') ' );
154
                }
153 155
            }
154 156
            // Inser the user into the database
155 157
			$sql  = 'INSERT INTO `'.TABLE_PREFIX.'users` SET '.

Also available in: Unified diff