MOON
Server: Apache/2.2.34 (Unix) mod_ssl/2.2.34 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4 FrontPage/5.0.2.2635
System: Linux server.asjudinet.com 2.6.32-042stab141.3 #1 SMP Fri Nov 15 22:45:34 MSK 2019 i686
User: asjudine (504)
PHP: 5.2.17
Disabled: NONE
Upload Files
File: /home/asjudine/public_html/comercial/formulario_consultorio_policia_bonificacion.php
<?php 
require_once("../Conectarse.php");   
   
   
   if(isset($_POST["guardar"]))
		{
			
		$fecha_asignac = date("Y")."-".date("m")."-".date("d");
		$nombre_completo =$_POST["nombre"]." ".$_POST["apellidos"] ;
		
	/////////////////
		$controlarte = mysql_query('SELECT cedula FROM cartera_serviasjudinet  WHERE cedula = "'.$_POST["ced"].'" ');
			if (!$controlarte) {
				die('Invalid query: ' . mysql_error());
			}
		$fil = mysql_num_rows($controlarte);
		
		list($cantipro) = mysql_fetch_row($controlarte);
		
		
		if ($fil != 0)
			{  
			
$mssql3 = mysql_query("UPDATE cartera_serviasjudinet set tipo_proceso= 'BONIFICACION JUDICIAL' WHERE cedula = '".$_POST["ced"]."' and tipo_proceso= '' " );
			
			}
	
	
	//////////////////	
	
		
		
$csql = mysql_query("SELECT cedula FROM consultorio_bonificacion WHERE cedula= '".$_POST["ced"]. "' and apellidos= '".$_POST["apellidos"]. "' and nombres= '".$_POST["nombre"]. "' ");	
			if (!$csql) {
				die('Invalid query: ' . mysql_error());
				
			} 		

if ((mysql_num_rows($csql)==0))


{
		
$csql6 = mysql_query("INSERT INTO consultorio_bonificacion (apellidos,nombres,cedula,celular,email ,grado,estado_civil,unidad, direccion_residencia,ciudad_residencia,actuaciones,estado,correo_alterno,tipo_proceso) VALUES ('" . $_POST["apellidos"] . "','" .$_POST["nombre"]. "', '".$_POST["ced"]. "', '" .$_POST["celular"]. "', '" .$_POST["email"]. "','" .$_POST["grado"]. "','" .$_POST["ecivil"]. "', '" .$_POST["unidad"]. "',  '" .$_POST["direccion"]. "', '".$_POST["ciudad"]."','".$_POST["mensaje"]."','6','".$_POST["emailalt"]."','BONIFICACION JUDICIAL')");	 
				
				if (!$csql6) { // esto es para que aparescan los errores
				die('Invalid query csql: ' . mysql_error()); 
					
			
							} 
	
		
	echo "<script>alert('Los datos fueron grabados correctamente');</script>"; 
		
		
		}
		
else

{
	$ced=$_POST["ced"];  
	
	 echo "<script>alert('Usuario Ya Esta Registrado desea continuar');</script>";  
	 

	
	}
	}
		

?>
<!DOCTYPE HTML>
<html>
<head>
<title>Registro de Formulario Subsidio</title>
<meta http-equiv="X-UA-Compatible" content="IE=8; IE=9; IE=edge" />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
    *{margin: 0;padding: 0;}
    body{background-color:#EAEAEA;font-family:Geneva, Arial, Helvetica, sans-serif;}
    header {background-color: #B7271F; text-align: center;}
    
    .titulo{width: 100%;text-align: center;background-color: #dbd8c9;color: #b20606;padding: 6px 0;font-size: 18px;}
    table{margin: 0 auto;border: 8px solid #bebebe; text-align: center;}
    .divirmenu{text-align: center;}
    .irmenu{width: 200px;background-color: #1c4fa0;color: #fff; padding: 4px;border-radius: 6px;}
    .irmenu:hover{background-color: #67a0d9; color: #000;}
    
    .fecha{background-color: #d6e08b; padding: 2px;color: #000;font-size: 15px; text-align: center;}
    td{padding: 1px; border: 1px solid #a0a0a0;}
    .td{background-color: #e5e5e5; padding: 1px 30px;color: #00135F;font-size: 14px;font-weight: 600; text-align: center;}
	.direcciona{width: 200px;background-color: #D4090C;color: #fff; padding: 4px;border-radius: 3px;}
	.direcciona:hover{background-color: #67a0d9; color: #000;}
    .boton1{width:30%;background-color: #ffffff;color: #000;padding: 2px;border:2px solid #580000;border-radius:10px;}
    .boton1:hover{background-color: #6f0000;color: #fff;cursor: pointer;}
    input[type=text]{border-radius: 5px; padding: 3px;background-color: #FFFFF4;}
	  .tdder{background-color: #e5e5e5; padding: 1px 2px;color: #00135F;font-size: 12px;font-weight: 600; text-align: right;}
	.tdtitulo{background-color: #e3dec0; color: #b20606; padding: 2px; text-align: center; font-size: 12px; font-weight: 900}
    .tdfull{background-color: #fff; color: #000; padding: 1px; text-align: center; font-size: 12px;}
    .botonnew{width: 90px; background-color: #e3dec0;color: #b20606;padding: 1px;border-radius:5px;}
    .botonnew:hover{width: 90px; background-color: #cbbd6a;color: #000;padding: 1px;border-radius:5px;}
	.tdizq{background-color: #e5e5e5; padding: 1px 10px;color: #00135F;font-size: 12px;font-weight: 600; text-align: left;}
</style>
</head>
 
<body bgcolor="#EFEFEF" text="#000000" topmargin="0" leftmargin="0">
<header>
    <img src="../ELEMENTS/bannerInterasjudinet.png" alt="" width=" 700" height="70">
</header>

<table width="595">
         

 
  <tr>
    <td width="608" align="center">
 
      <table width="44%" bgcolor="#EFEFEF" align="center" border="0" cellspacing="0" cellpadding="6">
 <tr>
  
   <td align="center" bgcolor="#306090"><big style="color:#FFFFFF"><b>INGRESAR CONSULTA JURIDICA</big></td>
  
 </tr> 
 
 <tr>
   <td align="center" colspan="2">
 
<script>
function Verificar() {
	
	
if(document.frm.apellidos.value == "") {
  alert("Por Favor Escriba Los Apellidos");
  document.frm.apellidos.focus();
  return false;
 }	

 if(document.frm.nombre.value == "") {
  alert("Por Favor Escriba El Nombre");
  document.frm.nombre.focus();
  return false;
 }
 
 if(document.frm.ced.value == "") {
  alert("Por Favor Escriba El Numero De Cedula");
  document.frm.ced.focus();
  return false;
 }
 
 if(document.frm.ecivil.value == "") {
  alert("Por Favor Escriba El Estado Civil");
  document.frm.ecivil.focus();
  return false;
 } 
 
 return true;
}
</script>
 
     <form method="post" name="frm" onSubmit="return Verificar()">
       <table border="0" bgcolor="#EFEFEF" cellspacing="5">
 <!-- <td><div align="right"><strong> Fecha Registro</strong></div></td>
    <td><div align="left">
      <input name="dia" type="text" id="dia2" value="<?php echo date("d"); ?>" size="2" maxlength="2" readonly>
      <input name="mes" type="text" id="mes2" value="<?php echo date("m"); ?>" size="2" maxlength="2" readonly>
      <input name="ano" type="text" id="ano2" value="<?php echo date("Y"); ?>" size="4" maxlength="4" readonly>
    </div></td>
  </tr>  -->
  <tr>
    <td class="tdder">Apellidos:</td>
    <td class="tdizq"><input type="text" name="apellidos" size="50" maxlength="40"></td>
  </tr>
  <tr>
    <td class="tdder">Nombres:</td>
    <td><input type="text" name="nombre" size="50" maxlength="40"></td>
  </tr>
  <tr>
    <td class="tdder">Cedula de Ciudadania:</td>
    <td><input type="text" name="ced" size="50" maxlength="40"></td>
  </tr>
  <tr>
    <td class="tdder">Celular:</td>
    <td><input type="text" name="celular" size="50" maxlength="40"></td>
  </tr>
  <tr>
    <td class="tdder">Correo Electronico:</td>
    <td><input type="text" name="email" size="50"></td>
  </tr>
  
  
    <tr>
    <td class="tdder">Correo Alterno:</td>
    <td><input type="text" name="emailalt" size="50"></td>
  </tr>
  
  <tr>
    <td class="tdder">Grado:</td>
    <td><input type="text" name="grado" size="50"></td>
  </tr>
  
    <tr>
    <td class="tdder">Estado Civil:</td>
    <td class="tdizq"><input type="text" name="ecivil" size="5"></td>
  </tr>
  
  
    <tr>
    <td class="tdder">Unidad:</td>
    <td><input type="text" name="unidad" size="50"></td>
  </tr>


  <tr>
    <td class="tdder">Direccion Residencia:</td>
    <td><input type="text" name="direccion" size="50"></td>
  </tr>
  <tr>
    <td class="tdder">Ciudad Residencia:</td>
    <td><input type="text" name="ciudad" size="50"></td>
  </tr>
  
  
  
  
  
         </table>           
      </table><br>
 <b>Gestion De Telemercadeo<br>
     
 	 <textarea name="mensaje" cols="80" rows="8"><? echo $moticonsu?></textarea><br><br>
	  
	 
 	<input name="menu2" type="button" class="direcciona" id="menu2" onClick="window.location.href='menu_consultorio_bonificacion.php'" value="IR AL MENU" />  
    <input name="guardar" type="submit" class="direcciona" id="guardar" value="ENVIAR " /></td>
 </tr>
      </table><br>
 
    </td>  
  </tr>

</table>
 
</body>
</html>