Ver Mensaje Individual
  #1 (permalink)  
Antiguo 20/05/2009, 17:05
Avatar de ana_gloria
ana_gloria
 
Fecha de Ingreso: febrero-2008
Mensajes: 65
Antigüedad: 17 años
Puntos: 1
Confirm y php

Buenas tardes aqui les pongo mi codigo, la intencion es solamente una serie de instrucciones en caso de que sea true o false la variable respuesta, el asunto aqui esq no hace nada mi paginita jeje, les agradeceria mucho su orientación y ayuda, un saludo!

Código PHP:

<?php 
include("../dlls/conecta.php");
mysql_select_db("bdpruebas",$conecta);
$evento=$_GET["evento"];
$id_subasta=$_GET["id_subasta"];
$nombre=$_GET["nombre"];
$apep=$_GET["apep"];
$apem=$_GET["apem"];
$apoyo_solicitado=$_GET["apoyo_solicitado"];
$saldo_monto=$_GET["saldo_monto"];
if(
$apoyo_solicitado $saldo_monto)
{
            echo 
"<script> var respuesta = confirm('EL SALDO DEL MONTO ES MENOR AL APOYO SOLICITADO, EL PRODUCTOR DE TODAS FORMAS ACEPTA EL APOYO?');</script>";
                if(
$respuesta==true)
                {
                    
$sql "update tbl_subasta set status = 1, monto_rojo = 1, saldo_monto_rojo=".$saldo_monto." where id_evento = ".$evento." and id_subasta = ".$id_subasta."";
                    
mysql_query($sql$conecta) or die("error al actualizar el status del productor".mysql_error());
                    echo 
"<script>
                        alert('LA SOLICITUD DEL PRODUCTOR "
.strtoupper($nombre)." ".strtoupper($apep)." ".strtoupper($apem)." SE GUARDÓ  DE MANERA CORRECTA');document.location='realizar_subasta.php?evento=".$evento."';
                        </script>"
;
                }
                else
                {
                    echo 
"<script>document.location='realizar_subasta.php?evento=".$evento."';</script>";
                }
}
?>