Welcome to the LimeSurvey Community Forum

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

{Qcode.question} delete style

  • mi_for
  • mi_for's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
2 years 6 months ago #220333 by mi_for
{Qcode.question} delete style was created by mi_for
Hi all,

in my survey I have a couple of text-display questions showing the name of a person in the question text (qcodes are per1 to per5). The question text is formatted with "<h2>" and "<strong>". Later in the survey I am using those names of the persons as answer options in a multiple choice question. For this I set answer option 1 to {per1.question},  answer option 2 to {per2.question} and so on. So far so good, but when I now display the multiple choice question the original style from the questions per1 to per5 are kept. This means the answer options are displayed as h2 and strong.
My "dirty" solution was to change the display of h2 and strong in that question via css, but this seems quite shady.
Is there an easier or cleaner solution?

Cheers,
Michael
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #220344 by Joffm
Replied by Joffm on topic {Qcode.question} delete style
How do you get the names that you display in your text-display questions?
IF they are piped from another question or attribute by equation  you may use these.

Maybe it is better you show us the problem by sending an lss export of these relevant questions.

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #220345 by tpartner
Replied by tpartner on topic {Qcode.question} delete style

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: DenisChenu, mi_for
The topic has been locked.
  • mi_for
  • mi_for's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
2 years 6 months ago #220361 by mi_for
Replied by mi_for on topic {Qcode.question} delete style
Perfect. That's exactly what I was searching for.
Thank you so much.
Maybe an additional hint for others looking at the posting. When used in specifying the answer items ("edit subquestions") the full code is:
Code:
{strip_tags(per1.question)}
(I misplaced the brackets and parenthesis in the beginning)
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose