Have an idea?

Visit Sawtooth Software Feedback to share your ideas on how we can improve our products.

Remove Clickable events of a checkbox

Hi,
I want to remove the clickable class of the following checkboxes.

Q1_17
Q1_18
Q1_19
Q1_20

Please let me know how to do this.
asked Dec 20, 2021 by Abdul Bronze (3,220 points)
Can you expound on what your end goal is?  Do you want to make some items exclusive and others not perhaps?
I want to add sub-headers in a question. I tried sub-headers from question library but it doesn't have option to randomize the blocks and to randomize the items within the blocks.

https://sawtoothsoftware.com/resources/question-library/subheaders

So I created a regular question and hided some of the response checkboxes to show as headers.

The problem is, respondent able to click on (only) headers and move on to the next question. So I want to remove the clickable class of the response option which is shown as headers.

I tried something like below but it doesn't work

<script type="text/javascript">
$(document).ready(function ($) {
$("#Q1_17_graphical").parent("td").removeClass("clickable");
   });
</script>

1 Answer

+1 vote
 
Best answer
Hi Abdul,

Please try this.

<script type="text/javascript">
$(document).ready(function ($) {
$("#Q1_17_graphical").closest('.clickable.response_row').css('pointer-events','none');
});
</script>


Regards,
Rahul Mittal
answered Dec 21, 2021 by Rahul Mittal Gold (11,860 points)
selected Dec 21, 2021 by Abdul
Rahul, It works great. Thank you so much.
...