align text left

More
5 years 5 months ago #81605 by dgrimard
dgrimard created the topic: align text left
Hello everyone,

I was trying to align the sub-questions in a table to the left using the text editor and it did not work in version 1.92+. I had to copy this little code : <div style="text-align: left"> that i new work from a previous lime survey version and copy-paste it at the start of every sib-question. Now it works but I find it strange to be unable to do that with the current text editor where a different code appeared and it did not work at all.

Any insights anyone?

Please Log in to join the conversation.

More
5 years 5 months ago #81628 by tpartner
tpartner replied the topic: align text left
The alignment is probably set in the template so you need to add a style rule that takes precedence (is stronger) than that.

The specifics would depend on which template you are using.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in to join the conversation.

More
5 years 5 months ago #81629 by Mazi
Mazi replied the topic: align text left
Please post a link to an activated sample survey so we can have a look at the source code details.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 5 months ago #81726 by dgrimard
dgrimard replied the topic: align text left
Well here is an example (the survey is in french). The first subquestion i used the current text editor and it does not alin to the left. For the rest of subquestions I used the old code <div style="text-align: left"> and it did align to the left.

Here is the link to my example: http://webdev/limesurvey/index.php?sid=82249&newtest=Y&lang=fr

Please Log in to join the conversation.

More
5 years 5 months ago #81797 by Mazi
Mazi replied the topic: align text left
Is that survey hosted on your local machine? Because I can't access the survey.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 3 months ago #83927 by rejeanp
rejeanp replied the topic: align text left
Hello,

One way I found interesting since only one line of code has to be changed is to edit the "template.css" file in the particular template you are using.

For instance, for the "citronade" template, I search the template.css file for the table.question custom tag and found this at line 634:

table.question tbody th.answertext,table.question tbody th.arraycaptionleft{text-align:right;}

All I did was to change the alignment of the text in this way:

table.question tbody th.answertext,table.question tbody th.arraycaptionleft{text-align:left;}

Now all your surveys using this template will have the questions (subquestions) align to the left

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!