The easyer way would be to say in the exit link
http://www.myexit.org/thanks.php&\(PASSTHRU:user\)
where the user-value "ABCDEF" from the incoming link is sent.
There are only two steps to implement a variable passthru, to pass any argument you like from the calling url:
1. in the index.php there are some lines to add (V1.90RC1 lines 2512ff)
// Check if the current survey language is set - if not set it
// this way it can be changed later (for example by a special question type)
//Check if a passthru label and value have been included in the query url
if(isset($_GET['passthru']) && $_GET['passthru'] != "")
if(isset($_GET[$_GET['passthru']]) && $_GET[$_GET['passthru']] != "")
$_SESSION['passthrulabel']=$_GET['passthru'];
$_SESSION['passthruvalue']=$_GET[$_GET['passthru']];
// NEW orvil: if no passthru variable is explicitely set, save the whole query_string
else
$_SESSION['ls_initialquerystr']=$_SERVER['QUERY_STRING'];
// end code
2. something to add in the common.php function passthruReplace($line, $thissurvey) (V1.90RC1 lines 3326ff)
function passthruReplace($line, $thissurvey)
$line=str_replace("\(PASSTHRULABEL\)", $thissurvey['passthrulabel'], $line);
$line=str_replace("\(PASSTHRUVALUE\)", $thissurvey['passthruvalue'], $line);
// NEW orvil: replacement for variable passthru argument like PASSTHRU:myarg
while (strpos($line,"\(PASSTHRU:") !== false)
$p1 = strpos($line,"\(PASSTHRU:"); // startposition
$p2 = $p1 + 10; // position of the first arg char
$p3 = strpos($line,"",10); // position of the last arg char
$cmd=substr($line,$p1,$p3-$p1+1); // extract the complete passthru like "PASSTHRU:myarg"
$arg=substr($line,$p2,$p3-$p2); // extract the arg to passthru (like "myarg")
// lookup for the fitting arg
$qstring = $_SESSION['ls_initialquerystr']; // get initial query_string
parse_str($qstring, $keyvalue); // split into key and value
$match = 0; // prevent an endless loop if there is no arg in url
foreach ($keyvalue as $key=>$value) // lookup loop
if ($key == $arg) // if match
$line=str_replace($cmd, $arg . "=" . $value, $line); // replace
$match = 1;
break;
if ($match == 0)
$line=str_replace($cmd, $arg . "=", $line); // clears "PASSTHRU:myarg to "myarg=" if there was no myarg in calling url
return $line;