AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Funciones WLanguage / Comunicación / Funciones HTTP
WINDEV
WindowsLinuxJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac Catalyst
Otros
Procedimientos almacenados
Añade o modifica una cookie en una solicitud HTTP.
Existen dos tipos de uso:
  • Si se ejecuta la solicitud con la función HTTPRequest, se debe llamar a la función HTTPCookieWrite antes de la función HTTPRequest para establecer el valor de las cookies que se enviarán al servidor HTTP.
Note Cookies read and sent by the HTTPRequest function are only stored in the application's memory. They are not related to the cookies of Web browsers installed on the computer.
Ejemplo
// Sets the value of an identification cookie with a stored value
HTTPCookieWrite("domain.com", "ID", LoadParameter("ID"))
 
// Performs an HTTP request
HTTPRequest("www.MySite.com?Login")
 
// Retrieves and stores the value of the cookie returned by the server
sID is string = HTTPCookieRead(".mysite.com", "ID")
SaveParameter("ID", sID)
Sintaxis

Solicitud ejecutada por HTTPRequest Ocultar los detalles

HTTPCookieWrite(<Domain> , <Name> , <Value>)
<Domain>: Cadena de caracteres
Validity domain of cookie.
The cookie will be sent into all HTTP requests whose domain ends with the validity domain of cookie.
For example, a cookie whose validity domain is ".mydomain.fr" will be sent during the following requests:
  • http://mydomain.fr
  • http://www.mydomain.fr/index.html
  • http://server.mydomain.fr/page.awp
It will not be sent in the following requests:
  • http://www.mydomain.com
  • http://otherdomain.fr
<Name>: Cadena de caracteres
Name of cookie.
This name is not case sensitive.
<Value>: Cadena de caracteres
Value of cookie.
Remarks:
  • The value of a cookie is limited to 4KB. Beyond this size, the server is free to reject the cookie.
  • The control characters (TAB, CR, etc.) as well as the semicolon and the binary zeros are not allowed.
Observaciones
  • Si la gestión de cookies no fue habilitada por HTTPCookieManage, las cookies no son enviadas al servidor:
  • La cookie se crea si no existe.
Componente: wd300com.dll
Versión mínima requerida
  • Versión 15
Esta página también está disponible para…
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 30/09/2024

Señalar un error o enviar una sugerencia | Ayuda local