<?php
// $Id: auth.php,v 1.6 2003/12/10 15:56:11 ronbakker Exp $
/**
* Authentication code
* @package Mambo Open Source
* @Copyright (C) 2000 - 2003 Miro International Pty Ltd
* @ All rights reserved
* @ Mambo Open Source is Free Software
* @ Released under GNU/GPL License : http://www.gnu.org/copyleft/gpl.html
* @version $Revision: 1.6 $
**/

defined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' );
global $mosConfig_absolute_path;
if (isset( $_REQUEST['base_path'] )) {
	$base_path = '';
}
$temp_dir = getcwd();
chdir( $base_path );

require_once( "configuration.php" );
require_once( "classes/mambo.php" );

$option = '';
if (!isset( $database )) {
	$database = new database( $mosConfig_host, $mosConfig_user, $mosConfig_password, $mosConfig_db, $mosConfig_dbprefix );
}
if (!isset( $mainframe )) {
	$mainframe = new mosMainFrame( $database, $option, '.' );
	$mainframe->initSession();
}
if (!isset( $my )) {
	$my = $mainframe->getUser();
}
chdir( $temp_dir );
?>