include_once "include/conexion.php";
include_once "include/sesion.php";
$conexion = new Conexion();
if (!$conexion->conectar()) {
    header('Location: ../');
}
$sesion = new Sesion();
if (!$sesion->is_logged()) {
    if (!$sesion->login()) {
        header('Location: ../');
    } else {
        header('Location: .');
    }
} else {
    if (isset($_REQUEST['action']) && $_REQUEST['action'] == 'salir') {
        $sesion->logout();
        header('Location: ../');
    }
}
include_once "include/lista_articulos.php";
session_start();
if (!isset($_SESSION["lista_articulos"])) {
    $_SESSION["lista_articulos"] = new ListaArticulos();
}
?>
<!DOCTYPE HTML>
<html lang="es">
    <head>
        <title>Zonda &rArr; Sistema de gesti&oacute;n web</title>
        <meta name="generator" content="Netbeans IDE 7.4 (2013)">
        <meta name="author" content="Juan Manuel Scarciofolo">