- Posts: 9
- Thank you received: 0
Ask the community, share ideas, and connect with other LimeSurvey users!
if (isset($_SESSION[$this->sessid]) && $this->surveyOptions)
{
$query .= $_SESSION[$this->sessid];
//If the responses already have been submitted once they are marked as completed already, so they shouldn't be changed.
$oSurveyResponse = SurveyDynamic::model($this->sid)->findByAttributes(]);
$result = true;
if ($oSurveyResponse->submitdate == null || Survey::model()->findByPk($this->sid)->alloweditaftercompletion == 'Y') {
$result = !Yii::app()->db->createCommand($query)->query();
//$result = !dbExecuteAssoc($query);
}
if ($result)
{
// TODO: This kills the session if adminemail is defined, so the queries below won't work.
$message = submitfailed('', $query); // TODO - report SQL error?
With your current settings : it's the needed behaviour (but error sent too admin is bad (i think i report this issue)).egisupport wrote: Upon checking it appears that multiple users are using the same token and updating at different times. After one user completes the survey further updates fail and an email is sent.
What is in the Expression Manager? Explain what confuses you.egisupport wrote: The more I look at this code the more confused I get. Like why is it in the Expression Manager?
Then your issue was this oneegisupport wrote: We need token based persistence so we cannot turn it off. Its a long survey involving school children which may need to be stopped and started at will.
We cannot have multiple responses for one token. Each token is assigned to a particular student we cannot have the same token with multiple students. One of the reasons this is required is for security, if our database is hacked we cannot release the name and personal details of students. Therefore the token is the only way to identify the student.
egisupport wrote: Upon checking it appears that multiple users are using the same token and updating at different times. After one user completes the survey further updates fail and an email is sent.
I still don't get how every student gets the URL including the token to enter the survey.egisupport wrote: I am pretty certain this is a simple case of students copying other students tokens however due to a number of different reasons I do not want to state that as fact until I am confident the issue is not software based.
You can easily test …egisupport wrote: Can I ask how "Disable multiple access of a survey with same token (if Enable token-based response persistence is ON)." works?