align pictures after text in the same line

More
6 months 3 weeks ago #151210 by KompetenzZ
KompetenzZ created the topic: align pictures after text in the same line
Hello,

I try to align the images in the answer options in the center, or still better with "margin-right: ...em", but I don't know how. I don't would like to use space because it is imprecise (and I also would have to insert spaces in the translation for other languages). I tried to do it with css but I don't know what exactly to write there to define classes.
I also tried "text-align: center", but it places the whole line in the center and I would need something which only moves the images, without the text, staying in the same line. See picture.
Attachments:

Please Log in to join the conversation.

More
6 months 3 weeks ago - 6 months 3 weeks ago #151219 by jacob
jacob replied the topic: align pictures after text in the same line
Can you provide a test-link ?
So its easier to understand what you've done so far (template / css etc.).
Last Edit: 6 months 3 weeks ago by jacob.

Please Log in to join the conversation.

More
6 months 3 weeks ago #151241 by KompetenzZ
KompetenzZ replied the topic: align pictures after text in the same line
Here is the testlink, it's the second question:

survey.toscani.at/index.php/533211?lang=de


(sorry for the German language in the survey)
Thank you

Please Log in to join the conversation.

More
6 months 3 weeks ago #151244 by holch
holch replied the topic: align pictures after text in the same line
I would personally put the picture before the text. Which would also resolve your problem.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in to join the conversation.

More
6 months 3 weeks ago - 6 months 3 weeks ago #151245 by jacob
jacob replied the topic: align pictures after text in the same line
you can add
img{
float: right;
}
to your css/template.css (template_editor).

BUT be carefull all other pictures will also have that float. So maybe you have to adjust other img with inline css. (float: none).
And i also agree with holch. I think pictures before text would be better.

hope it helps :)
jacob
Last Edit: 6 months 3 weeks ago by jacob.

Please Log in to join the conversation.

More
6 months 3 weeks ago #151256 by jelo
jelo replied the topic: align pictures after text in the same line

jacob wrote: float: right;jacob

The float right may work, if text isn't to long. But personally I wouldn't do it. Not sure how some browser display the stuff. I have not the Kompetenz to imagine ;-)

Attachments:

Please Log in to join the conversation.

More
6 months 3 weeks ago - 6 months 3 weeks ago #151257 by KompetenzZ
KompetenzZ replied the topic: align pictures after text in the same line
I see, the code is executed for all pictures. Thats a pitty, is there any possibility use the float only for this page? Otherwise the logo and other pictures will be misaligned.
I guess with defing classes, but I don't know how...
Placing the picture before the text is not an option for me in this case.
Last Edit: 6 months 3 weeks ago by KompetenzZ.

Please Log in to join the conversation.

More
6 months 3 weeks ago #151272 by jacob
jacob replied the topic: align pictures after text in the same line
yeah sorry,
big mistake there...

define id's (or classes) for your images like
<img alt="" id="myID_123456" src="/upload/surveys/123456/images/1.jpg" style="width: 198px; height: 256px;" />Bild 1

Then you can customize the appearance of your images.
with:

#myID_123456{
myCSS: xyz;
}

maybe that will work
The following user(s) said Thank You: KompetenzZ

Please Log in to join the conversation.

More
6 months 3 weeks ago - 6 months 3 weeks ago #151276 by jelo
jelo replied the topic: align pictures after text in the same line

KompetenzZ wrote: Thats a pitty, is there any possibility use the float only for this page?

I added the float only to the images in my screenshot example.
You can add float via the GUI of the image properties as well.
Attachments:
Last Edit: 6 months 3 weeks ago by jelo.
The following user(s) said Thank You: DenisChenu

Please Log in to join the conversation.

More
6 months 3 weeks ago - 6 months 3 weeks ago #151318 by KompetenzZ
KompetenzZ replied the topic: align pictures after text in the same line
Thank you Jelo, but this GUI is not the same because I can't align the picture in center in this case.

However, at the end I would like to place the answer option "chopped straw" at the top of the second column. I set "Display columns: 2", but I can't change the division of the columns. I would need 5 answer options in the first column and 6 answer options in the second column (to avoid white space after the "Other" answer option). See picture.
Attachments:
Last Edit: 6 months 3 weeks ago by KompetenzZ.

Please Log in to join the conversation.

More
6 months 3 weeks ago #151331 by holch
holch replied the topic: align pictures after text in the same line
This won't work. Limesurvey will always devide this way, more responses in the first columns than in the last, if it is uneven. This works absolutely fine in 99% of the cases. Now in your case it is also no problem, but rather a visual inconvenience. I wouldn't spent tooooo much time on these details. At the end of the day they don't really matter.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now