<?php
  if( !isset( $_REQUEST['nBrowser'] ) )
  {
    Header("Location: index.php");
    exit;
  }// End if( !isset( $_REQUEST['nBrowser'] ) )
  // Arquivo de definições
  include_once("include/phPage.define.php");
?>
  <title> <?php echo( TIT_VER );?> </title>
<?php

  $dirJS = $_REQUEST["nBrowser"];
  $iniJS = "<script type=\"text/javascript\" ";
  $endJS = "</script> \n";
  
  switch( DEBUG )
  {
    case '0':
      echo( "<script type=\"text/javascript\" src=\"startUP.core.js\"></script> \n" );
      break;
    case '1':
      echo( "<!-- JavaScripts --> \n" ) ;
      echo( $iniJS . " src=\"".INC."mainJavaScript.js\"></script> \n" );

      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/findDOM.js\">" . $endJS );
      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/wddx.js\">" . $endJS );
      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/wddxDes.js\">" . $endJS );
      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/jsrsClient.js\">" . $endJS );
      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/msgIndex.js\">" . $endJS );

      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/index.js\">" . $endJS );
      echo( $iniJS . " src=\"lib_JS/" . JS_DIR . "/EventoGlobal.js\">" . $endJS );
      echo( "<!-- End JavaScripts --> \n\n" );

      echo( "<!-- Folha de Estilos --> \n" );
      include_once( CSS."index.css");
      echo( "<!-- End Folha de Estilos --> \n" );
      //echo('startUP');exit;
      break;
      
    default:
      echo( "<!-- JavaScripts --> \n" ) ;
      
      echo( JS_START );
      include( INC."/mainJavaScript.js" );
      include( "lib_JS/" . $dirJS . "/findDOM.js" );
      echo( JS_END );
      echo( $iniJS . " src=\"lib_JS/" . $dirJS . "/wddx.js\">" . $endJS );
      echo( $iniJS . " src=\"lib_JS/" . $dirJS . "/wddxDes.js\">" . $endJS );
      echo( JS_START );
      include( "lib_JS/" . $dirJS . "/jsrsClient.js" );
      include( "lib_JS/" . $dirJS . "/msgIndex.js" );
      include( "lib_JS/" . $dirJS . "/index.js" );
      include( "lib_JS/" . $dirJS . "/EventoGlobal.js" );
      echo( JS_END );
      echo( "<!-- End JavaScripts --> \n\n" );

      echo( "<!-- Folha de Estilos --> \n" );
      include_once( CSS."index.css");
      echo( "<!-- End Folha de Estilos --> \n" );

  }// End switch( DEBUG )
?>
</head>

<body id="bodyMain">

<?php
  if(!isset($_REQUEST["nameUSER"])  )
  {
/**
 *  Tela de Login  //
 *  =============  //
 */
    include( "startUP_login.php" );
  }else
  {
/**
 *  Modo de Edição  //
 *  ==============  //
 */
    include( "startUP_studio.php" );
  }// End if(!isset($_REQUEST["nUser"])  )
?>
</body>
</html>

