* @copyright 2008 Bartolomé Sintes Marco * @license http://www.gnu.org/licenses/agpl.txt AGPL 3 or later * @version 2008-03-02 * @link https://www.mclibre.org * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . */ session_start(); include "biblioteca.php"; $db = conectaDb(); if (!isset($_SESSION["multiagendaIdioma"]) && !isset($_REQUEST["idioma"])) { $_SESSION["multiagendaIdioma"] = $administradorIdioma; cabecera(_("Elección de idioma"), "menu_principal"); print "

" . _("Por favor, elija el idioma del interface") . "

\n"; print "\n"; menuIdioma(); $_SESSION["multiagendaIdioma"] = NULL; } else { if (isset($_REQUEST["idioma"])) { $_SESSION["multiagendaIdioma"] = recogeIdioma(); header("Location:$_SERVER[PHP_SELF]"); exit; } $consulta = $consultaExisteTabla; $result = $db->query($consulta); if (!$result) { print "

" . _("Error en la consulta") . ".

\n"; print "\n"; } elseif ($result->fetchColumn() == 0) { cabecera(_("Primera conexión"), "menu_principal"); print "

" . _("Aparentemente, la base de datos no existe. Se creará a continuación") . ".

"; print "\n"; if ($dbMotor == MYSQL) { borraTodoMySQL($db); } elseif ($dbMotor == SQLITE) { borraTodoSqlite($db); } } else { if (isset($_SESSION["multiagendaUsuario"])) { cabecera(_("Inicio"), $_SESSION["multiagendaUsuario"]); } else { cabecera(_("Identificación") . " 1", "menu_principal"); $aviso = recogeParaConsulta($db, "aviso"); $aviso = quitaComillasExteriores($aviso); if ($aviso) { print "

$aviso

\n"; print "\n"; } print "
\n"; print "

" . _("Escriba su nombre de usuario y contraseña") . ":

\n"; print "\n"; print " \n"; print " \n"; print " \n"; print " \n"; print " \n"; print " \n"; print " \n"; print " \n"; print " \n"; print "
" . _("Nombre") . ":
" . _("Contraseña") . ":
\n"; print "\n"; print "

\n"; print "\n"; print "

" . _("Nota") . ": " . _("Si no está ya registrado, le registraré como nuevo usuario") . ".

\n"; print "
\n"; print "\n"; } } } pie();