Tema: Delete
Ver Mensaje Individual
  #7 (permalink)  
Antiguo 16/11/2004, 13:25
Avatar de christopher1979
christopher1979
 
Fecha de Ingreso: octubre-2004
Mensajes: 203
Antigüedad: 19 años, 6 meses
Puntos: 0
<?php

$clavefrente1 = $_POST['clavefrente'];

$nombrefrente1 = $_POST['nombrefrente'];

$ubicacion1 = $_POST['ubicacion'];

$calle1 = $_POST['calle'];

$numero1 = $_POST['numero'];

$colonia1 = $_POST['colonia'];

$cp1 = $_POST['cp'];

$ciudad1 = $_POST['ciudad'];

$estado1 = $_POST['estado'];

$telefono1 = $_POST['telefono'];

$residente1 = $_POST['residente'];

$connection = mysql_connect("localhost","administrador","adminis trador");

mysql_select_db("destajos",$connection);


mysql_query("DELETE FROM frentes where clavefrente = '$clavefrente1' and nombrefrente = '$nombrefrente1'and ubicacion = '$ubicacion1' and calle = '$calle1' and numero = '$numero1' and colonia = '$colonia1' and cp = '$cp1'
and ciudad = '$ciudad1' and estado = '$estado1' and telefono = '$telefono1' and residente = '$residente1'",$connection);



echo "<form name=\"retorno\" action=\"modelifrente1.php\">

BORRADO EL REGISTRO

<script type=\"text/javascript\">

document.retorno.submit()

</script>

</form>";


?>


este es el codigo que borra pero como le ago para que no lo borre si tengo registros en otras tablas la llave en todas es clavefrente