The LimeSurvey Fund-Raiser 2012 is complete. Thank you for donating a total of 25,000 USD!     List of donors »

Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: Confirm Results/Unanswered Questions

Confirm Results/Unanswered Questions 2 years 4 days ago #61055

  • andrewteg
  • andrewteg's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
I would like to add a page after all my questions that shows the answers and hopefully highlights any non-mandatory questions that were skipped so the takers realize they skipped some questions before they submit the responses. Is this possible?

Also, I have "list with comment" questions but if they choose something and do not fill in a comment the "question index / allow jumping" feature marks it as not answered but I want it marked as answered. Is this possible?

Thanks,
Andrew
The administrator has disabled public write access.

Re: Confirm Results/Unanswered Questions 2 years 4 days ago #61061

  • tpartner
  • tpartner's Avatar
  • NOW ONLINE
  • LimeSurvey Team
  • Posts: 2864
  • Thank you received: 424
  • Karma: 244
1) You can use {INSERTANS} to display answers to previous questions - docs.limesurvey.org/Adding+a+question&hi...rom_previous_answers

2) I'm afraid I don't understand "the "question index / allow jumping" feature marks it as not answered". Could you please elaborate or provide a screenshot?
Cheers,
Tony

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.
The following user(s) said Thank You: andrewteg

Re: Confirm Results/Unanswered Questions 2 years 4 days ago #61062

  • andrewteg
  • andrewteg's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
Thanks Tony.

1) I can certainly use this and probably will. Somewhat related do you know when the printable results link is supposed to come up? I could not find how to get to that page after taking a survey.

2) I attached a screenshot of a question but basically I answer it (pick a radio button), click Next, and then click Previous and it says it is not complete (in red with missing class) because I did not fill out a comment. It is a list with comment question type and I'd like to have it marked as complete once the user picks a radio button. (Since the question is marked as incomplete the section is in the Question Index feature as well which is what I referenced originally but I hope it's clearer to see on a specific question)

Thanks again for your help!
Andrew
Attachments:
The administrator has disabled public write access.

Re: Confirm Results/Unanswered Questions 2 years 3 days ago #61110

  • andrewteg
  • andrewteg's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
FYI, I have found some solutions browsing around.

1) I like the idea at ideas.limesurvey.org/ideatorrent/idea/225 as the review/print ability is needed before submission on certain questionnaires. For now I found www.limesurvey.org/en/forum/future-featu...e-submitting-answers asking what I want so I guess using {INSERTANS} on a boilerplate at the end is the best solution to date, but that's disappointing as you cannot reuse question text with that method.

2) I have found the solution by editing the common_function bCheckQuestionForAnswer as follows for anyone interested:
/**
 * Check if a question was (at least partially) answered in the current session.
 *
 * @param integer $q - Question id
 * @param array $aFieldnamesInfoInv - Inverted fieldnamesInfo
 */
function bCheckQuestionForAnswer($q, $aFieldnamesInfoInv)
{
	//echo "TYPE=".$_SESSION['fieldmap'][$aFieldnamesInfoInv[$q][0]]['type']."|";
    if(@$_SESSION['fieldmap'][$aFieldnamesInfoInv[$q][0]]['type'] != 'M' && @$_SESSION['fieldmap'][$aFieldnamesInfoInv[$q][0]]['type'] != 'O')
    {
        // all answers required
        $bAnsw = true;
        foreach($aFieldnamesInfoInv[$q] as $sField)
        {
            if(!isset($_SESSION[$sField]) || trim($_SESSION[$sField])=='')
            {
                $bAnsw = false;
                break;
            }
        }
    } elseif (@$_SESSION['fieldmap'][$aFieldnamesInfoInv[$q][0]]['type'] == 'O') {
		// list with comment, just list is required
		//echo "<PRE>"; print_r($aFieldnamesInfoInv[$q]); echo "</PRE>";
        $bAnsw = false;
        foreach($aFieldnamesInfoInv[$q] as $sField) {
            if(!strstr($sField, 'comment') && isset($_SESSION[$sField]) && trim($_SESSION[$sField])!='') {
                $bAnsw = true;
                break;
            }
        }
    } else {
        // multiple choice, just one answer is required
        $bAnsw = false;
        foreach($aFieldnamesInfoInv[$q] as $sField)
        {
            if(isset($_SESSION[$sField]) && trim($_SESSION[$sField])!='')
            {
                $bAnsw = true;
                break;
            }
        }
	}
    return $bAnsw;
}

Thanks for the help all, and please let me know if anyone finds an easier way to have a review screen before submission!

Thanks,
Andrew
The administrator has disabled public write access.

Re: Confirm Results/Unanswered Questions 2 years 3 days ago #61111

  • tpartner
  • tpartner's Avatar
  • NOW ONLINE
  • LimeSurvey Team
  • Posts: 2864
  • Thank you received: 424
  • Karma: 244
Andrew, regarding item 2 - in my opinion, this is a bug. When setting the question to mandatory, the textarea is not required so I don't think it should be required for the "question index / allow jumping" feature.

Could you please file a bug report and include your description, screenshot and fix?
Cheers,
Tony

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
Last Edit: 2 years 3 days ago by tpartner.
The administrator has disabled public write access.

Re: Confirm Results/Unanswered Questions 2 years 3 days ago #61112

  • andrewteg
  • andrewteg's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
The administrator has disabled public write access.
  • Page:
  • 1
Moderators: DenisChenu, ITEd
Time to create page: 0.253 seconds
Donation Image