Ver Mensaje Individual
  #11 (permalink)  
Antiguo 03/05/2005, 19:02
darksteel01
 
Fecha de Ingreso: mayo-2005
Mensajes: 49
Antigüedad: 18 años, 11 meses
Puntos: 0
ayuda...

Cita:
Iniciado por pepotis
Pues antes de hacer el update tienes que leer los datos, sería algo así:
Código PHP:
$result=mysql_db_query("basededatos","SELECT sight from article where id='".$_GET['id']".' limit 1");
while(
$row=mysql_fetch_array($result)){
$sight=$row["sight"]+1;//Y ya ta sumado
}
//ahora haces el update
mysql_db_query("base de datos","UPDATE article SET sight='$sight' WHERE id='".$_GET['id']."'"); 
para que cuente, habria que hacer una página aparte, o sólo hacemos un if de la get = contar blah blah, porfavor expliquenme...

darksteel-