Feedback Print

Events

Scriptcase uses the events to enable the developer to customize the application code. Using the events you can program custom actions at a specific execution time (e.g. After a record is inserted, when it is loaded, upon submitting a form, …) and for a specific application type. In the event areas you can use global and local variables, JavaScript, CSS, HTML, PHP codes and also Scriptcase macros.

onApplicationInit

This event occurs only once, when the application is loaded and before the application executes the SQL. It can be used for data processing or checking variables.

Example: if ([glo_var_dept] != ‘financial’){ sc_redir(app_x.php); }

OnScriptInit

This event occurs when the application scripts are started. It runs before the OnLoad events(when present), however, it will always be executed when running, reloading or navigating the application.

onHeader

This event runs when the header of the application is loaded.

onFooter

This event runs when the footer of the application is loaded.