Ver Mensaje Individual
  #1 (permalink)  
Antiguo 31/10/2008, 11:16
Avatar de hoberwilly
hoberwilly
 
Fecha de Ingreso: julio-2008
Ubicación: Lima - Perú
Mensajes: 769
Antigüedad: 15 años, 10 meses
Puntos: 2
Pregunta Ayuda por favor con esto...

Hola amigos, quisiera por favor me ayuden con los siguientes codigos:
pedidoPendiente.php
----------------------------
include('conec.php');
conectarse();
$qry=mysql_query("select * from factura where estatus='pendiente'");
?>
<html>
<head>
<title>Administrador de Pedidos Pendientes</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<table>
<tr>
<td align="center" width="4%"><strong>Id</strong></td>
<td align="center" width="21%"><strong>Destinatario</strong></td>
<td align="center" width="10%"><strong>Fecha Pedido</strong></td>
<td align="center" width="5%"><strong>Acci&oacute;n</strong></td>
</tr>
<?php
while($row=mysql_fetch_array($qry)){
?>
<tr valign="middle" class='prod' onmouseover='this.style.background="#f2f2f2"' onmouseout='this.style.background=""'>
<td align="center"><?php echo $row['idFactura'] ?></td>
<td><?php echo $row['destinatario'] ?></td>
<td align="right"><?php echo $row['fechaFactura'] ?></td>
<td align="center"><?php echo "<a href=\"actualizarPedido.php?idFactura=".$row['idFactura']."\">Actualizar</a>" ?></td>
</tr>
<?php } ?>
</table>
</body>
</html>

y actualizarPedido.php
----------------------------
<?php
include('conec.php');
conectarse();
$estatus = "atendido";
$sql="update factura set estatus='$estatus' where idFactura='".$_GET['idFactura']."'";
mysql_query($sql) or die( "Error en $sql, error: " . mysql_error() );
header("location: index.php");
return;
?>

la implementacion corre (el usuario selecciona actualizar de la lista y lo cambia al estado atendido), pero quiero realizar algunos cambios como por ejemplo:

-----------------------------------------------------------------------------------------------
id destinatario fecha pedido accion
----- ---------------- ------------------ ---------
001 hober willy 31-10-2008 radiobutton1
002 willy hober 01-11-2008 radiobutton2
etc

||boton1 para consultar pedido pendiente||
||boton2 para cancelar pedido pendiente||
------------------------------------------------------------------------------------------------
al seleccionar un solo radio boton y click en el boton "consultar pedido pendiente", me consulte solo por ejemplo el id de la facturación 001. No se si esta claro...

Agradeciendo sus colaboraciones de antemano...