Welcome, Guest
Username: Password: Remember me

TOPIC: Make Multiple Short Text Answers a Bit Longer?

Make Multiple Short Text Answers a Bit Longer? 2 years 7 months ago #77182

  • acp_tests
  • acp_tests's Avatar
  • OFFLINE
  • Junior Lime
  • Posts: 30
  • Karma: 0
I want to use the multiple short text questions type but I would like to make the text boxes a little longer. I know you can enter more text and it will scroll, but is there any way (maybe in the template CSS?) to make them wider so the user can see their entire entry? I want to make them about twice as wide as they are.
The administrator has disabled public write access.

Aw: Make Multiple Short Text Answers a Bit Longer? 2 years 7 months ago #77207

  • Steve
  • Steve's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 494
  • Thank you received: 46
  • Karma: 17
Hello,

you should be able to solve this with a little css rule. If you want to change a single answer the code would look like
#answer82472X3X4931 {
    width: 300px;
}
You have to change 82472X3X4931 into the SGQA code of your answer and 300px into the width you want to have.

If you want to apply this to all text boxes you might want to use
.answers-wrapper input.empty[type="text"] {
    width: 300px;
}
instead.
Mit freundlichen Grüßen/Best regards,

Stefan Gohlke
LimeSurvey Team
The administrator has disabled public write access.

Re: Aw: Make Multiple Short Text Answers a Bit Longer? 2 years 7 months ago #77249

  • acp_tests
  • acp_tests's Avatar
  • OFFLINE
  • Junior Lime
  • Posts: 30
  • Karma: 0
Thank you very much for replying. I seem to be a bit confused so please bear with me.

First, I assume you mean to put this code in template.css in the Template Editor. I have copied the default template to a new one called ACPDefault and I have a set my survey to use this template.

I do not see that class, .answers-wrapper, or anything like it in the template.css. I'm wondering if we're using different versions. I'm using 1.91+ on LimeService.

Anyway, looking at the page source for the questions I want to alter, I see this HTML:
<li>
 <label for="answer69491X60X385NAME">Enter your full name:</label>
 <span>
   <input class="text " type="text" size="20" name="69491X60X385NAME" id="answer69491X60X385NAME" value="" onkeyup="noop_checkconditions(this.value, this.name, this.type);"  maxlength="255" />
 </span>
</li>

I want that size="20" to be size="50". That's it. But I tried adding some things based on these styles to the bottom of the template.css and they did not affect the appearance. In fact, if I bring up the page and do a page source, I see that it's access the CSS file "ACPDefault/template.css" BUT if I put the full path for that file in my browser I see a template.css but it does not have my modifications! I'm obviously doing something wrong. I am making the changes in the template editor and I am saving them. If I log out and log back in and go back to the Templated Editor I see the changes. But when I access the CSS directly from my browser I don't see them.

Not sure what I'm doing wrong...
The administrator has disabled public write access.

Re: Aw: Make Multiple Short Text Answers a Bit Longer? 2 years 7 months ago #77254

  • TMSWhite
  • TMSWhite's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 82
  • Karma: 36
acp_tests-

Another solution is to to use the input box width advanced question option. If that doesn't work, there may be a bug in that feature (which could be easily fixed).
The administrator has disabled public write access.

Re: Aw: Make Multiple Short Text Answers a Bit Longer? 2 years 7 months ago #77261

  • acp_tests
  • acp_tests's Avatar
  • OFFLINE
  • Junior Lime
  • Posts: 30
  • Karma: 0
No it works just fine, but I couldn't find it. :blink: Thanks!
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.154 seconds
Donation Image