
09/01/2002, 11:48
|
| | Fecha de Ingreso: enero-2002
Mensajes: 55
Antigüedad: 23 años, 3 meses Puntos: 0 | |
Re: Cookies Urgente No se que pasa pero lo hago de esa forma y no funciona.
Los usuarios ven el asp votacion.asp cuando presionan el voton de votar, se redirecciona al asp vota.asp en este es donde creo la cookies en la rutina cuando vota le asigno SI a la cookies
esta es la rutina
Sub VOTA ()
Set Command1 = Server.CreateObject("ADODB.Command")
Command1.CommandText = "inserta_voto"
Command1.Parameters.Append Command1.CreateParameter("@RETURN_VALUE" , 3, 4)
Command1.Parameters.Append Command1.CreateParameter("@id_video", 3, 1,4, id_video)
Command1.CommandType = 4
Command1.CommandTimeout = 0
Command1.Prepared = true
Set voto = Command1.Execute
if voto.fields.item("error").value = 1 then
MenError = "Error en consulta de datos..."
else
Response.Cookies("key") = "si"
Response.Cookies("key").Expires = Date
end if
Set voto = Nothing
Set Command1 = Nothing
End Sub
Y cuando la llamo hago esto
if Request.Cookies("key") = "si" then
response.write ("usted ya voto")
else
call VOTA()
end if
Pero no funciona :( |