ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Web-specific functions / Browser functions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Retrieves the value of a cookie saved on the computer of Web user.
// Retrieves the name and date of last visit
NameAndDate is string
NameAndDate = CookieRead("NAMEANDDATE") // NAMEANDDATE: name of the cookie
IF NameAndDate = "" THEN
// first visit
MyMessage = "Welcome, new visitor!"
ELSE
TheName = ExtractString(NameAndDate, 1, ",")
MyMessage = "Welcome " + TheName
TheDate = ExtractString(NameAndDate, 0, ",")
END
Syntax
<Result> = CookieRead(<Cookie name>)
<Result>: Character string
  • Value of the cookie,
  • Empty string ("") if the cookie does not exist on the computer of Web user.
<Cookie name>: Character string
Name of the cookie to be read on the user computer. This name was used when the cookie was created by CookieWrite.
Remarks
  • WEBDEV - Server code Reminder: When the Web user connects to a WEBDEV site, the Web server loads all the cookies associated with the current domain in memory.
    Note: The Internet domain corresponds to a specific section of the Internet address: http://computer.domain.com/MyPages/Index.html.
  • WEBDEV - Browser code In browser code, CookieRead directly reads the value of the specified cookie on the user's computer.
  • If your project uses pre-launched sessions, this function must not be used in the project initialization event. It must be used in the event "Initializing the project after connection to the site".
Business / UI classification: UI Code
Component: wd290page.dll
Minimum version required
  • Version 9
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help