Пример #1
0
function Guardar()
{
    $destinop = new DestinoCiudad();
    if (isset($_POST['nombre_destino']) && $_POST['nombre_destino'] != "") {
        $nombre = $_POST['nombre_destino'];
        $pais = $_POST['pais_destino'];
        $estatus = $_POST['estatus_destino_val'];
        //$belcorp = $_POST['ciudad_Belcorp'];
        if ($belcorp == "on") {
            $belcorpc = 1;
        } else {
            $belcorpc = 0;
        }
        $destinop->Nuevo_Destino($nombre, $pais, $estatus);
        header("Location: index.php?oksave");
    } else {
        header("Location: index.php?error");
    }
}