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

TOPIC: keep order of response in a multiple choice question

keep order of response in a multiple choice question 2 years 10 months ago #68004

  • rafael_ur
  • rafael_ur's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 74
  • Karma: 0
Hi,

I have a multiple choice question and I need to keep order of response for first three responses. How could I do it?

Many thank,
Rafael
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68027

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5325
  • Thank you received: 296
  • Karma: 249
Simply don't set "randomize answer options" at the advanced question settings :-)

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68028

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4193
  • Thank you received: 789
  • Karma: 359
Do you mean the order in which the respondent clicks them?

If so, is the survey in "group by group" mode so you can have a hidden question on the page?
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68033

  • rafael_ur
  • rafael_ur's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 74
  • Karma: 0
Hi Mazi,

What I need is to identify it down first, second and third place on the multiple chice question, I don't want to have to ask three questions single. Is it possible?

Thanks,
Rafael
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68036

  • rafael_ur
  • rafael_ur's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 74
  • Karma: 0
Hi Tony,

Yes I need the order in which the respondent clicks them.

Thanks,
Rafael
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68041

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4193
  • Thank you received: 789
  • Karma: 359
1) Set up your survey to use JavaScript.

2) Add a short-text question to the page with the multiple-options question.

3) Add the following script to the source of the short-text question. Replace "11" with the multiple-options question ID and "HH" with the short-text question ID.

If a checkbox in the multiple-options question is checked, its answer code is added to an array. When the Next/Submit button is clicked, the array is loaded into the hidden question storing the answer codes listed in order of checking.
<script type="text/javascript" charset="utf-8">
 
	$(document).ready(function() {
 
		var q1ID = 11;
		var qHidden = HH;
 
		$('#question'+qHidden+'').hide();
 
		var q1Answers = new Array();
 
		// Build an array of q1 answers checked
		$('#question'+q1ID+' input.checkbox').click(function(){
			var ansIDArr = $(this).attr('id').split('X'+q1ID+'');
			var ansCode = ansIDArr[1];
			if($(this).attr('checked') == true) {
				q1Answers.push(ansCode);
			}
		});
 
		// Interrupt next/submit function 
		$('#movenextbtn, #movesubmitbtn').click(function(){
 
			$('#question'+qHidden+' input.text').val(q1Answers);
 
			return true;
		});
 
	});
</script>
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68051

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5325
  • Thank you received: 296
  • Karma: 249
Thanks for clarifying. Why don't you just use a ranking question?

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68056

  • rafael_ur
  • rafael_ur's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 74
  • Karma: 0
Toni,

Fantastic,
this is what I needed.


Many thanks,

Rafael
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68060

  • rafael_ur
  • rafael_ur's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 74
  • Karma: 0
Mazi,

Could be, but otherwise fills.

Many thanks,
Rafael
The administrator has disabled public write access.

Re: keep order of response in a multiple choice question 2 years 10 months ago #68593

  • cegreja
  • cegreja's Avatar
  • OFFLINE
  • Junior Lime
  • Posts: 25
  • Karma: 0
Hi. I find this useful. However, I don't understand how you then make use of the ranked labels. I'd like to apply this script and then select the first option to the formulation of question A, the second choice in question B and the third option in question C, for example. I don't understand how that's done.

I found this in the manual: docs.limesurvey.org/tiki-index.php?page=...estion_for_later_use

However, I don't want it to be randomized. I'd like the three options selected to correspond to 3 different questions.

Thanks a lot
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Moderators: ITEd
Time to create page: 0.132 seconds
Donation Image