<?php
/*
  ===============================================================

  inGenio X
  http://ingenio.area421.com

  Created by 
  Julian Moreno Hidalgo (Software developer)
  Jesus Moreno Hidalgo (Communication's tree)

  inGenio X is a free software licensed under CC-GNU GPL

  ===============================================================
*/

	// valor "1" en desarrollo y "0" en internet
	ini_set("display_errors", "0");

	// Attempt...
	define("IGNX", 1);

	// funciones
	include("./ints/inc_funciones.php");

	// conectar
	$ingenio_conn = array();
	include("./igns/ingenio_conn.php");
	myconnect($ingenio_conn[0],$ingenio_conn[1],$ingenio_conn[2],$ingenio_conn[3]);

	// modo
	define("INGENIO_X_MODO", "prev"); // previsualizar web

	// configurar
	$qig = myquery("SELECT * FROM ".INGENIO,"[getprev=conf]");
	while ($row_qig = myfetch($qig))
	{
		define("CONFIG_".$row_qig["igID"], $row_qig["topic"]);
	}
	include("./ints/core/core.modr.php");

	// idioma
	$qid = myquery("SELECT * FROM ".IDIOMA_ADMIN,"[getprev=lens]");
	while ($row_qid = myfetch($qid))
	{
		if ($row_qid["topic_pre"]  != "")
		{
			define("LEN_ADMIN_".$row_qid["lenID"], $row_qid["topic_pre"]);
		} else {
			define("LEN_ADMIN_".$row_qid["lenID"], $row_qid["topic"]);
		}
	}

/******* CONFIGURACION  ***********/

$titulo = INGENIO_NOMBRE." : ".LEN_ADMIN_294; // previsualizar web

/******* CONFIGURACION FIN ********/

	$no_get = $_SERVER['QUERY_STRING'] == "" ? 1 : 0 ;
	$ig = $_GET;

	// inicio
	session_start();
	
	// autorizar al administrador
	$redir_admin = "";
	include("./".$ingenio_conn[7]."/inc.login.php");

	
	// ver pag
	if ($no_get)
	{
		$conID = "";
		$ver_pag = NOMBRE_DOMINIO.RUTA_INICIO."len".IGUAL."0";
	
	}
	

?>
<!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php  echo CONFIG_2; ?>">
<?php
// si hay favicon
if (CONFIG_3 != "+") {
?>
<link rel="sortcut icon" href="<?php  echo RUTA_INICIO_IMG.CONFIG_3; ?>" type="image/ico">
<?php
}
?>
<title><?php  echo $titulo; ?></title>

</head>

<frameset cols="*" frameborder="0" border="0">
	<frame src="<?php echo $ver_pag; ?>" name="vercontenido" frameborder="0" border="0" scrolling="auto">
</frameset>

</html>