NIPO ODIN Version 5.17

Previous Topic

Next Topic

Example Using Adobe Flash in NIPO CAWI and NIPO CAPI

This section describes how to display Adobe Flash content and capture its output in the data of a NIPO ODIN questionnaire in NIPO CAPI and NIPO CAWI.

The basic idea to transfer information between the Flash application and the ODIN script is to make use of JavaScript on the pages. The Flash application should be created in a way that it at the end of the user interaction makes a call to a predefined JavaScript function with the resulting values of the Flash application. The JavaScript function receives these values and will pass them to the corresponding fields generated by the NIPO ODIN questionnaire.

The JavaScript functions and the Flash application can be included in the NIPO ODIN template for the specific question where the Flash application is used. The NIPO ODIN question can be designed as a *FORM question with the regular fields (*ALPHA or *NUMBER) to store the values. Depending on the selected question type, the necessary JavaScript may need changes to actually fill in the answer into the right fields on the page. These fields should however not be actually shown on the page, so CSS is used to hide these fields on the page. This means the fields will not be visible, but they will exist in the HTML page, and as such can be updated by the JavaScript function.

Depending on the type of data to send from Flash to the JavaScript function, it may be necessary to explicitly format the data as an array in Flash (instead of passing a string) to make sure JavaScript also recognizes the data as an array.

This section provides an example on how JavaScript may be used to create the link between the Flash application and the HTML generated by the NIPO ODIN script. It does not explain how the actual Flash application should be created.

See Also