protected function _getAbsoluteDirectory( $relativeDir )
	{
		$config = $this->_getContext()->getConfig();

		if( ( $dir = $config->get( 'controller/extjs/media/default/basedir', null ) ) === null ) {
			throw new Controller_ExtJS_Exception( 'No base directory configured' );
		}

		/** controller/extjs/media/default/upload/dirperms
		 * Directory permissions used when creating sub-directories
		 *
		 * Uploaded files are stored in sub-directories of the configured upload
		 * directory depending on the domain (e.g. product, catalog, service,
		 * etc.) and these directories can also contain more directories. Each
		 * directory is created with the configured permissions.
		 *
		 * The representation of the permissions is in octal notation (using 0-7)
		 * with a leading zero. The first number after the leading zero are the
		 * permissions for the web server creating the directory, the second is
		 * for the primary group of the web server and the last number represents
		 * the permissions for everyone else.
		 *
		 * You should use 0775 or 0755 for the permissions as the web server needs
		 * to write into the new directory and the files are publically available,
		 * so it's not necessary to limit read access for everyone else. The group
		 * permissions are important if you plan to upload files directly via FTP
		 * or by other means because then the web server needs to be able to read
		 * and manage those files. In this case use 0775 as permissions, otherwise
		 * you can limit them to 0755.
		 *
		 * A more detailed description of the meaning of the Unix file permission
		 * bits can be found in the Wikipedia article about
		 * {@link https://en.wikipedia.org/wiki/File_system_permissions#Numeric_notation file system permissions}
		 *
		 * @param integer Octal Unix permission representation
		 * @since 2014.03
		 * @category Developer
		 * @category User
		 */
		$perms = $config->get( 'controller/extjs/media/default/upload/dirperms', 0775 );
		$dir .= DIRECTORY_SEPARATOR . $relativeDir;

		if( is_dir( $dir ) === false && mkdir( $dir, $perms, true ) === false )
		{
			$msg = sprintf( 'Couldn\'t create directory "%1$s" with permissions "%2$o"', $dir, $perms );
			throw new Controller_ExtJS_Exception( $msg );
		}

		return $dir;
	}