Follow

Advanced Survey Options

Advanced Survey Options

Starting with version 6.5 the survey system includes several advanced features. The advanced survey options allow the user to create elaborate surveys using field dependent regions (areas that can be hidden or revealed when a user-defined criteria is met) and field validation (limits the responses for number, date, and time field).

 

It is recommended that users have a working knowledge of HTML before proceeding with using the advanced options. Otherwise, feel free to contact Samaritan's Client Services team.

 

Shown below is the "Edit Survey" screen showing the "advanced survey options" section:

If so desired, the advanced survey options can be hidden.

 

Below are some examples of how the advanced survey options can be used.

 

 


 

Field Dependent Regions

 

The most important concept to grasp is that of Field Dependent Regions (FDR). Simply put, a FDR is an "if/then" statement; as in "if the volunteer fills in _____ field, then display _____ field." An example may be that in a survey, you would like to know if a volunteer enjoyed his/her experience, so you ask "Did you enjoy your volunteer experience?" followed by a dropdown with options of "Yes" and "No." If the volunteer selects "No," you would like to know why, so a text box appears below the question after selecting "No." If "Yes" is selected, no additional fields appear.

 

This is an example a Value field dependent region, meaning the region appears only when a certain value is selected for a defined field.
Field full dependent regions mean that the region appears if any value is selected, or if the field is not blank.
Field empty dependent regions mean that the region appears only when the defined field has no value selected, or is left blank.
Field validation error region means that user will get an error if the field does not meet certain requirements. For example, email addresses must follow the "name@domain.com" format. If the information that is entered this field does not meet that criteria, it cannot be validated, and the error appears.

 

 


 

Nesting table cell contents within a FDR

 

To make a table cell be hidden or visible based on a FDR, you must use a table-in-td structure.

 

Example:

 

<tr><td>

[DREGION::FULL::Hours]

<table>

<tr><td style="width: 50%">Service Performed</td><td>[Service Performed]</td></tr>

</table>

[/DREGION]

</td></tr>

 

 

 


 

Field Value dependent region syntax

 

Field Value dependent regions enable the user to hide certain regions based on the data currently present in the specified field.

 

Example of a basic field value dependent region:

 

[DREGION::option::value="Yes"::yes/no] [/DREGION]

 

For number, date, and time fields it is possible to insert field value dependent regions for which the value in the field is compared against any one of the standard numeric comparison operators (<, <=, =, >=, >).

 

[DREGION::option::value>12::Hours][/DREGION]

 

Example of an and criteria being used:

 

<td style="width: 50%">Benches Color</td>

<td style="width: 50%">[Bench Color]

[DREGION::option::value="Red" and value="Green"::Bench Color]

Thank you for painting our Special Edition benches[/DREGION]

</td>

 

Example of an or criteria being used:

 

[DREGION::option::value="9" or value="10"::Experience Quality]

 

 

 


 

Field Validation

 

For number, date, and time fields it is possible to insert field validation for fields that the user would like to limit the responses.

 

Example of a validation check on the "Hours" field that limits the volunteer to 24 hours per entry:

 

[DREGION::validation_error::value>"24"::Hours]

<font color="#ff0000">Invalid Number of hours. </font>[/DREGION]

 

This code would not allow the volunteer to submit the above survey if they put any number greater than 24 in the hours field.

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk