This translation is older than the original page and might be outdated. See what has changed.
Translations of this page:
 

This is an old revision of the document!


panelData()

array panelData()

The command panelData() provide the allocation of a participant to a subgroup (index 0) and the data, which is given as user defined data in the address records, in an array (indices 1 to 5).

Important: The function provide a value only, if the interview was started by click at the personalized link in a mass mail (else zero). In case the participant is forwarded automatically to the survey, after an Opt-In-Confirmation, (Multi-Wave Surveys with Self-Recruited Respondents), than this is equivalent to the click at the personalized link in a mass mail.

Example

The following example is based on the assumption, that the name of the company is placed in field 1 of the address record. Now, the name of the company should be used as the content of the placeholder %company%.

$data = panelData();
if ($data === null) {
  // error message and stop of the survey,
  // if the survey was not opened by a serial letter
  text('no data');
  buttonHide();
  pageStop();
}
$company = $data[1];
replace('%company%', $company);
en/create/functions/paneldata.1466945169.txt.gz · Last modified: 26.06.2016 14:46 by s1305605
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
Driven by DokuWiki