Welcome, Guest
Username: Password: Remember me

TOPIC: Adding validation to text field - multiple short text

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71709

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4118
  • Thank you received: 760
  • Karma: 346
If the question is a multiple-short-text type, the selector should be "#answer38194X3X115SQ012".
Cheers,
Tony Partner

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

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71710

  • miradoro
  • miradoro's Avatar
  • OFFLINE
  • Expert Lime
  • Posts: 92
  • Karma: 0
thanks let me try that
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71716

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5324
  • Thank you received: 293
  • Karma: 248
You can set Limesurvey to show all codes at the printable survey screen, see this setting:
"$showsgqacode: (>1.91) This setting is used at the printable survey feature Image and defaults to false. If you set $showsgqacode = true; the IDs for each question - and answer if applicable - will be shown; these IDs match the column heading at the Lime_survey_12345 table which holds the answer data for a certain survey. These Ids can be used for a code book for manual database queries."
Link to optional settings

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71720

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4118
  • Thank you received: 760
  • Karma: 346
Or use Firebug for Firefox to inspect the element.
Cheers,
Tony Partner

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

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71728

  • miradoro
  • miradoro's Avatar
  • OFFLINE
  • Expert Lime
  • Posts: 92
  • Karma: 0
the validation works
but the problem is that i am using groups

the email is on the first group...when u go to next group i still see the validation..i am using js script
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71740

  • TMSWhite
  • TMSWhite's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 82
  • Karma: 36
In 1.92 RC2, you can use preg (validation) for emails (and other things) in multiple short text. It will validate twice. First, if you try to enter an invalid email address, the background color of the input box will change to red. Then, if you submit an invalid value, it will return you to the same page and alert you that there were validation errors. If 1.92 stable is ready in time for your needs, that might be easier than the JavaScript-based solution.
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71782

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4118
  • Thank you received: 760
  • Karma: 346
...when u go to next group i still see the validation..
Did you place the script in the source of the question?
Cheers,
Tony Partner

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

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71783

  • miradoro
  • miradoro's Avatar
  • OFFLINE
  • Expert Lime
  • Posts: 92
  • Karma: 0
nope

i added it on stargroup file

let me try...is there a section where i can add?
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71784

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5324
  • Thank you received: 293
  • Karma: 248
You have to add such code in source code mode of the editor when editing a question.

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.

Re: Adding validation to text field - multiple short text 2 years 7 months ago #71793

  • tpartner
  • tpartner's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 4118
  • Thank you received: 760
  • Karma: 346
Cheers,
Tony Partner

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

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.130 seconds
Donation Image