Both sides previous revisionPrevious revisionNext revision | Previous revision |
en:create:functions:caseserial [16.12.2014 12:37] – [Example] alexander.ritter | en:create:functions:caseserial [21.04.2024 20:18] (current) – admin |
---|
''string **caseSerial**()'' | ''string **caseSerial**()'' |
| |
The function ''caseSerial()'' returns the value saved in the data record in the variable ''SERIAL''. This is useful for example, if you would like to show the respondent a personalized link to another questionnaire. | The function ''caseSerial()'' returns the value saved in the data record in the variable ''SERIAL''. This is useful, for example, if you would like to show the respondent a personalized link to another questionnaire. |
| |
* If the participant was invited via [[:en:survey:mailing|Mailing]], ''caseSerial()'' returns the personal ID of the participant. | * If the participant was invited via [[:en:survey:mailing|Mailing]], ''caseSerial()'' returns the personal ID of the participant. |
* If an authorization code was used to begin the questionnaire (either transferred in the [[:en:survey:url|Link]] or entered manually, this will be returned when ''caseSerial()'' is used. | * If an access code was used to begin the questionnaire (either transferred in the [[:en:survey:url|Link]] or entered manually), this will be returned when ''caseSerial()'' is used. |
| |
**Note:** An authorization code in the link to the questionnaire is saved regardless of whether the the questionnaire can only be accessed with an authorization code or is public. To tranfer an ID that is not an authorization code, it is better to use the reference designed for this purpose. | **Note:** An access code in the link to the questionnaire is saved regardless of whether the the questionnaire can only be accessed with an access code, or if it is public. To tranfer an ID that is not an access code, it is better to use the reference designed for this purpose. |
| |
**Hinweis:** Eine Seriennummer im Link zum Fragebogen wird unabhängig davon gespeichert, ob der Fragebogen nur via Seriennummer oder öffentlich zugänglich ist. Zum Übergeben einer Kennung, die keine Seriennummer ist, sollte allerdings besser die dafür ausgelegte Referenz verwendet werden. | |
| |
===== Example ===== | ===== Example ===== |
</code> | </code> |
| |
The authorization code or the personal ID is also available with the [[:en:create:placeholders|placeholder]] %caseSerial% . The following PHP code has the same purpose a the code above. | The access code or the personal ID is also available with the [[:en:create:placeholders|placeholder]] %caseSerial% . The following PHP code has the same purpose a the code above. |
| |
<code php> | <code php> |