Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

textbox in array

  • barbacot
  • barbacot's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 5 months ago #110574 by barbacot
textbox in array was created by barbacot
I must create an array question where the first column is with text inputs and the rest of the columns are radio buttons.

I used the code from here as an inspiration and arrived at this:
Code:
<script>
 
$(document).ready(function(){
    $('#question{QID}  tbody tr td:last-child').each(function(){
        var textinputid=$(this).find('input:radio').attr('id');
        $(this).find('input:radio').hide();
        $(this).append("<input type='text' data-copy='"+textinputid+"' />");
    });
});
</script>

The problem is that the text input column is the last one (probably because of td:last-child) buyt i don't know how to move it in the first position (see screenshot)


Attachments:
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Away
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 years 5 months ago - 10 years 5 months ago #110579 by tpartner
Replied by tpartner on topic textbox in array
I'm not sure what those text inputs will do for you.

Have a look at this post - www.limesurvey.org/en/forum/design-issue...to-text-input#102550


.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 10 years 5 months ago by tpartner.
The topic has been locked.
  • barbacot
  • barbacot's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 5 months ago #110591 by barbacot
Replied by barbacot on topic textbox in array

tpartner wrote: I'm not sure what those text inputs will do for you.

Have a look at this post - www.limesurvey.org/en/forum/design-issue...to-text-input#102550


.


Thanks A LOT for the link - it was exactly what i needed!
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose