Please help us help you and fill where relevant:
LimeSurvey version: [see right hand bottom of your LimeSurvey admin screen]
Own server or LimeSurvey Cloud:
Survey theme/template:
==================
(Write here your question/remark)
Please help us help you and fill where relevant:
LimeSurvey version: [see right hand bottom of your LimeSurvey admin screen]
Own server or LimeSurvey Cloud:
Survey theme/template:
==================
(Write here your question/remark)
Please help us help you and fill where relevant:
LimeSurvey version: LimeSurvey Cloud Version 6.5.13
Own server or LimeSurvey Cloud: LimeSurvey Cloud
Survey theme/template: Extended from Fruity
==================
Hello,
I used the following code to make one of my question's last two rows exclusive. I was wondering if someone could help me do the same thing but instead make the last two columns exclusive, please?
Thank you!<script type="text/javascript" data-author="Tony Partner">
$(document).on('ready pjax:scriptcomplete',function(){
var thisQuestion = $('#question{QID}');
var firstRow = $('tr.subquestion-list:eq(0)', thisQuestion);
// Listener on the first row checkboxes
$(':checkbox', firstRow).on('change', function(e){
$(':checkbox', thisQuestion).prop('disabled', false);
if($(this).is(':checked')) {
var thisCell = $(this).closest('td');
var thisIndex = $(thisCell).index();
// Render this checkbox exclusive in this row
var otherRowCells = $('td.answer-item', firstRow).not(thisCell);
$(otherRowCells).
each
(function(i) {
$('input[type="hidden"]', this).val('');
$(':checkbox', this).prop('checked', false).trigger('change');
});
// Render this checkbox exclusive in this column
var otherColCells = $('td.answer-item:nth-child('+(thisIndex+1)+')').not(thisCell);
$(otherColCells).
each
(function(i) {
$('input[type="hidden"]', this).val('');
$(':checkbox', this).prop('checked', false).trigger('change').prop('disabled', true);
});
}
});
});
</script>
Attachment not found