config_dir="../config"; $o_smarty->compile_dir="../templates_c"; $o_smarty->config_load("app.conf", basename($_SERVER['SCRIPT_NAME'],".php")); $agent = &Net_UserAgent_Mobile::factory(); session_start(); if( $agent->isDoCoMo() ) { header("Location: " . $o_smarty->get_config_vars("sitetopurl") . $cnt_com_dir . "/docomo/index.php?". session_name() . "=" . session_id() ); exit; }elseif ( $agent->isJPhone() ) { header("Location: " . $o_smarty->get_config_vars("sitetopurl") . $cnt_com_dir . "/vodafone/index.php?". session_name() . "=" . session_id() ); exit; }elseif ( $agent->isEZweb() ) { header("Location: " . $o_smarty->get_config_vars("sitetopurl") . $cnt_com_dir . "/au/index.php?" . session_name() . "=" . session_id() ); exit; }else { header("Location: " . $o_smarty->get_config_vars("sitetopurl") . $cnt_com_dir . "/pc/index.php" ); exit; } ?>