Returns the name of the page requested at the start of the session.
Remark: This function is particularly useful in the code of the project, to get the name of the page that will be returned.
SWITCH (SessionPageRequested())
CASE "PAGE_Admin"
// Checks the connection parameters on the URL
IF NOT ConnectUser() THEN
PageDisplay(PAGE_LoginError)
END
OTHER CASE
// Nothing
END
Syntax
<Result> = SessionRequestedPage()
<Result>: Character string
- Page name. Below are the different cases and the corresponding page name:
- Connection to a site in Session mode via an SEO-ready page: name of the SEO-ready page.
- Connection to a site in Session mode using DynamicSiteDisplay and specifying a page: name of the page (only if the appropriate access option is enabled in the page).
- Connection to a site in Session mode from a WINDEV application that requests a particular page: name of the page (only if the appropriate access option is enabled in the page).
- Displaying an Active WEBDEV Page: name of the Active WEBDEV Page.
- Empty string ("") in other cases, or if the function is called after the session start request.