37 lines
1.1 KiB
PHP
37 lines
1.1 KiB
PHP
<?php
|
|
include("conexion.php");
|
|
$con = Conectarse();
|
|
|
|
$folio = utf8_decode($_POST['folio']);
|
|
if ($folio == "") {
|
|
$folio = 'NULL';
|
|
}
|
|
$num_cuenta = trim($_POST['num_cuenta']);
|
|
if ($num_cuenta == "") {
|
|
$num_cuenta = 'NULL';
|
|
}
|
|
$nombre = utf8_decode(trim($_POST['nombre']));
|
|
$app = utf8_decode(trim($_POST['app']));
|
|
$apm = utf8_decode(trim($_POST['apm']));
|
|
$licenciatura = utf8_decode($_POST['licenciatura']);
|
|
$sistema = $_POST['sistema'];
|
|
$generacion = trim($_POST['generacion']);
|
|
$telefono = utf8_decode(trim($_POST['telefono']));
|
|
$celular = utf8_decode(trim($_POST['celular']));
|
|
$email = utf8_decode(trim($_POST['email']));
|
|
$proviene = $_POST['proviene'];
|
|
$informacion = $_POST['informacion'];
|
|
if ($informacion == "") {
|
|
$informacion = 'n';
|
|
}
|
|
|
|
$insert_registro = "call st_guarda_registro($folio, $num_cuenta, '$app', '$apm', '$nombre', $licenciatura, $sistema, '$generacion', '$telefono', '$celular', '$email', $proviene, '$informacion')";
|
|
$result = mysqli_query($con, $insert_registro);
|
|
//echo $insert_registro;return;
|
|
if ($result && $proviene == 1) {
|
|
echo 1;
|
|
} else if ($result && $proviene !== 1) {
|
|
echo 2;
|
|
} else {
|
|
echo 0;
|
|
} |