- Posts: 55
- Thank you received: 1
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Defining each column width in Array (Text) questions
- Vinicos
- Offline
- Senior Member
Less
More
4 years 1 week ago #197138
by Vinicos
Replied by Vinicos on topic Defining each column width in Array (Text) questions
I mean... it's the 3.17.7+190627 version
The topic has been locked.
- Joffm
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 12908
- Thank you received: 3975
4 years 1 week ago #197144
by Joffm
Volunteers are not paid.
Not because they are worthless, but because they are priceless
Replied by Joffm on topic Defining each column width in Array (Text) questions
Here you see
www.limesurvey.org/forum/can-i-do-this-w...rvey?start=15#186378
You may skip the statements that only refer to background-color.
So this is sufficient:
.custom-array table.subquestion-list thead .column-1 { width: 23%; }
.custom-array table.subquestion-list thead .column-2 { width: 15%; }
...
Joffm
www.limesurvey.org/forum/can-i-do-this-w...rvey?start=15#186378
You may skip the statements that only refer to background-color.
So this is sufficient:
.custom-array table.subquestion-list thead .column-1 { width: 23%; }
.custom-array table.subquestion-list thead .column-2 { width: 15%; }
...
Joffm
Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10103
- Thank you received: 3593
4 years 1 week ago #197146
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Defining each column width in Array (Text) questions
@Vinicos, are you trying to change the column widths or the text input widths?
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- Joffm
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 12908
- Thank you received: 3975
4 years 1 week ago #197147
by Joffm
Volunteers are not paid.
Not because they are worthless, but because they are priceless
Replied by Joffm on topic Defining each column width in Array (Text) questions
Oh, I saw that the "old", original post was about:
I am using limesurvey 2.50, I want to have different input box width for each multiple short text subquestions.
Alzheimer or the glasses get worse.
Joffm
I am using limesurvey 2.50, I want to have different input box width for each multiple short text subquestions.
Alzheimer or the glasses get worse.
Joffm
Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10103
- Thank you received: 3593
4 years 1 week ago - 4 years 1 week ago #197148
by tpartner
With Javascript:
With CSS:
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Defining each column width in Array (Text) questions
I have both.Alzheimer or the glasses get worse.
With Javascript:
Code:
<script type="text/javascript" charset="utf-8"> $(document).on('ready pjax:complete',function() { // Identify this question var thisQuestion = $('#question{QID}'); // First column $('td.answer-item:nth-child(2) input:text', thisQuestion).attr('size', 4); // Second column $('td.answer-item:nth-child(3) input:text', thisQuestion).attr('size', 20); }); </script>
With CSS:
Code:
<style type="text/css"> /* First column */ #question{QID} td.answer-item:nth-child(2) input[type="text"] { width: 50px; } /* Second column */ #question{QID} td.answer-item:nth-child(3) input[type="text"] { width: 150px; } </style>
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 4 years 1 week ago by tpartner.
The topic has been locked.
- Vinicos
- Offline
- Senior Member
Less
More
- Posts: 55
- Thank you received: 1
4 years 1 week ago #197150
by Vinicos
Replied by Vinicos on topic Defining each column width in Array (Text) questions
The column widths!
The topic has been locked.
- Vinicos
- Offline
- Senior Member
Less
More
- Posts: 55
- Thank you received: 1
4 years 1 week ago #197159
by Vinicos
Replied by Vinicos on topic Defining each column width in Array (Text) questions
It works well now!
Thanks very much!
Thanks very much!
The topic has been locked.