- Posts: 12
- Thank you received: 0
Ask the community, share ideas, and connect with other LimeSurvey users!
What LimeSurvey version are you using?If you could provide me with a script example of how to insert the names of the actors into the hidden multi-short-text question...
Which translates into what maximum?TSpeirs wrote: There is no maximum number of actors one person can select, but there is a limit of plausible answers (obviously).
We are using Version 2.67.2tpartner wrote: What LimeSurvey version are you using?
jelo wrote: Which translates into what maximum?
I was thinking of simple text-piping for the follow-up questions. We can't target the value of a "first checked" item in a multiple-choice but we can target the value in the first sub-question of a multi-short-text.I'm still wondering about the piping in the last step since EM isn't offering a dynamic list object to choose items from.
You said you have interacted with {qHidden_SQ001.shown}. How do you feel about...
If you could provide me with a script example of how to insert the names of the actors into the hidden multi-short-text question...
<script type="text/javascript" charset="utf-8"> $(document).ready(function() { // Identify the questions var thisQuestion = $('#question{QID}'); var hiddenQuestion = $(thisQuestion).nextAll('.multiple-short-txt:eq(0)'); // Interrupt the "Next" function $('#movenextbtn, #movesubmitbtn').on('click', function(e) { // Load the hidden question $('input[type="checkbox"]:checked', thisQuestion).each(function(i) { var thisText = $.trim($(this).nextAll('.label-text:eq(0)').text()); $('input[type="text"]:eq('+i+')', hiddenQuestion).val(thisText); }); }); }); </script>
I'm sorry but I don't understand what you mean by "empty rows". Are you referring to possible empty rows in the hidden question if less than the max actors is selected? If so, you simply place group-level relevance on the corresponding follow-up question sets like:That being said, we still need a way to hiding the empty rows created that way.
!is_empty(qHidden_SQ001)
So, you have actor-specific images? If so, depending on the image names, you should be able to do something like:We have used HTML in the description of our answer options <img src="">. Is there a way to pipe this too?
<img src="path/to/images/actor_{qHidden_SQ001.shown}.jpg" />