Websydian v6.1 online documentationOnline documentation - WebsydianExpress v3.0

API  - ReloadSitePageGenerator

Scoped Name

APIWebServer.ReloadSitePageGenerator

Interface

None

Description

Call this API if you have changed roles or user for the session and want to reload the site based on the new session information.

This can be used if you create a custom-made login functionality.

The API calls a PageGenerator that contains an event which reloads the site. In the HTML template WSLOAD used by this PageGenerator, this event is specified as having target ="_top" and the page includes JavaScript that executes this event automatically.

This template is delivered in the "basicsite" template folder. This template must be present in a folder in the folder list used by the session when the API is called - otherwise an error will be reported to the user and the site will not be reloaded.

In some cases, the user will see the page generated by the WSLOAD page for a moment before the reload is done. If you want to change the design of this page, you can do so by changing the template WSLOAD - but it is important that you do not remove the submit statement in the Initialization JavaScript and that the target for the event remains "_top".

The PageGenerator inherits from PageGeneratorNoPresentation, this means that you do not have to make  a special version for each presentation, it is always the basic WSLOAD template that will be used.

After calling the ReloadSitePageGenerator you are not allowed to call any other PageGenerator as this will generate an error.

Events

WSE0036 - Session not found

Universal events