'."\n" );
echo( ''."\n" );
ob_start();
if ( !isset($user) && ZM_OPT_USE_AUTH )
{
if ( ZM_AUTH_TYPE == "remote" && !empty( $_SERVER['REMOTE_USER'] ) )
{
$view = "postlogin";
$action = "login";
$username = $_SERVER['REMOTE_USER'];
}
}
require_once( 'zm_actions.php' );
if ( !isset($user) )
{
$view = "login";
}
elseif ( !isset($view) )
{
$view = "console";
}
switch( $view )
{
case "login" :
case "postlogin" :
case "logout" :
case "console" :
case "state" :
case "cycle" :
case "watch" :
case "montage" :
case "settings" :
case "events" :
case "filter" :
case "event" :
case "eventdetails" :
case "frame" :
case "monitor" :
case "video" :
case "function" :
case "none" :
{
require_once( "zm_".$format."_view_".$view.".php" );
break;
}
default :
{
$view = "error";
}
}
if ( $view == "error" )
{
require_once( "zm_".$format."_view_".$view.".php" );
}
//$fp = fopen( "/tmp/output.html", "w" );
//fwrite( $fp, ob_get_contents() );
//fclose( $fp );
ob_end_flush();
?>