Willkommen, Gast
Benutzername: Passwort: Angemeldet bleiben:

THEMA: Minimum and maximum values for numerical input - red notification text shows

Minimum and maximum values for numerical input - red notification text shows 3 Monate 4 Tage her #107884

Hello,

I'm trying to create a questionnaire with LimeSurvey but I'm having problems, when I set minimum and maximum values for (mandatory) "Numerical input" -questions.

First and most importantly, one of these questions works perfectly. With the other ones, immediately when entering the page and before inserting any answer, the questionnaire shows this "Each answer must be between 0 and 12" text in red and also the answering field is colored red. With all of these questions I chose "Hide tip -> yes". I already tried to open the questionnaire with a different browser (didn't help) and activated the survey and then answered it (didn't help either). I don't see any difference between constructing these questions (one of them doesn’t show this notification, the rest do), so I cannot figure out what went wrong.

Second, I would prefer this "Each answer must be between 0 and 12" text in Finnish, is there any way that I could enter it myself? I have set the language in Finnish and all the other texts in this questionnaire are automatically in Finnish and work perfectly.

I'm using LimeSurvey Version 2.00+ Build 121204.

If you know any solutions, I'm more than grateful, and please explain carefully, because this is so not my field of expertise.

Thank you very much!
Letzte Änderung: 3 Monate 4 Tage her von MarjaanaSianoja.
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Minimum and maximum values for numerical input - red notification text shows 3 Monate 4 Tage her #107891

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 4066
  • Dank erhalten: 745
  • Karma: 341
Can you attach a sample survey?
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.
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Minimum and maximum values for numerical input - red notification text shows 3 Monate 3 Tage her #107892

Thanks for answering! :)

Here's attached the questionnaire and then as an example question number 13, which is the first problematic one.

Let me know, if this wasn't what you were asking for :)
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Minimum and maximum values for numerical input - red notification text shows 3 Monate 3 Tage her #107897

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 4066
  • Dank erhalten: 745
  • Karma: 341
Hmm...seems to be a bug where if there is relevance assigned to the question the error text is initially shown.

To work around it, set up your survey to use JavaScript and add this to the source of all offending questions. If the numeric input is empty, the error text will be hidden.

<script type="text/javascript" charset="utf-8">	
	$(document).ready(function() {
 
		// Identify this question
		var thisQuestion = $('#question{QID}');
 
		if($('input[type="text"]', thisQuestion).val() == '') {
			$('.em_value_range, .numeric.em_sq_validation', thisQuestion).removeClass('error').addClass('good');
		}
	});
</script>

Regarding your second question, I don't see any English text. Perhaps you should update to the last stable version of 2.0 (131206).

Capture3_2014-04-24.png
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.
Der Administrator hat öffentliche Schreibrechte deaktiviert.
Moderatoren: ITEd
Ladezeit der Seite: 0.152 Sekunden
Donation Image