Willkommen, Gast
Benutzername: Passwort: Angemeldet bleiben:
  • Seite:
  • 1
  • 2

THEMA: No error message if validation fails

No error message if validation fails 1 Jahr 1 Monat her #93489

  • jonsen
  • jonsens Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 61
  • Dank erhalten: 2
  • Karma: 0
Dear all,

thank you for being such a great community for this amazing tool!

If I submit a page with validations errors on it (in my current survey on 1.92+), the page is just reloaded and there is no message to the user that (s)he should check for errors, nor is the error focus()ed. I made quite a lot of surveys with LS and I could have sworn that there was a Javascript alert() when there was a validation error and that the question with the error was focused.

Did I somehow break the mechanism? I adapted some css and added a Javascript function to block the Enter and Backspace keys. But I tested it without the JS function too, and it shows the same behaviour. I also tried a jQuery $(document).ready(function{ $('.error').first().focus(); }); to at least focus the first question with a validation error when the page is reloaded, but that didn't work either.

I would greatly appreciate some advice on where to look for the error.

Thank you!

Best
Jonsen
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93502

  • DenisChenu
  • DenisChenus Avatar
  • OFFLINE
  • Moderator Lime
  • Beiträge: 5850
  • Dank erhalten: 716
  • Karma: 222
Hello,

In general, there are validation error. Maybe some EM error or another think.

Can you put the lss file here or give us a link to test ?

Denis
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93518

  • jonsen
  • jonsens Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 61
  • Dank erhalten: 2
  • Karma: 0
Hello Denis,

please find the link below. I put the test-token in the link.

In diesem Beitrag ist für Gäste nicht alles sichtbar. Bitte melde dich an, oder registriere dich.

The first question is mandatory. I changed the class .good to have visibility: hidden.

Best
Jonsen
Letzte Änderung: 1 Jahr 1 Monat her von jonsen. Begründung: Added info
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93520

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 3813
  • Dank erhalten: 683
  • Karma: 328
It looks like your question.pstpl file might be missing some placeholders.

Test the survey with the default or citronade template and if those work, compare the question.pstpl files.
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.

No error message if validation fails 1 Jahr 1 Monat her #93526

  • jonsen
  • jonsens Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 61
  • Dank erhalten: 2
  • Karma: 0
Hi tpartner, thank you for your reply. I tested both default and citronade, the validation alert doesn't show there either. So it seems to be a problem that's template-independent...
Letzte Änderung: 1 Jahr 1 Monat her von jonsen. Begründung: typo
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93546

  • jonsen
  • jonsens Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 61
  • Dank erhalten: 2
  • Karma: 0
For anyone who provides a solution to this, I will speak out an invitation to a fresh beer in a bar or club in Berlin... :)
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93549

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 3813
  • Dank erhalten: 683
  • Karma: 328
jonsen, can you attach the sample survey and an export of your template?
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.

No error message if validation fails 1 Jahr 1 Monat her #93554

  • jonsen
  • jonsens Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 61
  • Dank erhalten: 2
  • Karma: 0
Yes, of course...

Attachments:
In diesem Beitrag ist für Gäste nicht alles sichtbar. Bitte melde dich an, oder registriere dich.

Best
Jonsen
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93562

  • jonsen
  • jonsens Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 61
  • Dank erhalten: 2
  • Karma: 0
jonsen schrieb:
For anyone who provides a solution to this, I will speak out an invitation to a fresh beer in a bar or club in Berlin... :)

I just now notice how cheap that sounds! Sorry... So now that includes a bed&breakfast :)

Anyways, the problem is that I don't know where to look for the error. I don't know at which place the code for this should be, so I can't trace it back to the php or anything...

Thanks alot for your help!

Best
Jonsen
Der Administrator hat öffentliche Schreibrechte deaktiviert.

No error message if validation fails 1 Jahr 1 Monat her #93563

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 3813
  • Dank erhalten: 683
  • Karma: 328
Hey, a beer is more than most folks offer us :laugh:

This is very odd - when I run the survey on my 1.92installation, with your template, everything works as expected. The pop-up alert appears and the "errormandatory" span is displayed - see below.

Dumb question, but have you updated to the final stable release of 1.92?

Capture_2013-03-11.JPG
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.
Folgende Benutzer bedankten sich: jonsen
  • Seite:
  • 1
  • 2
Moderatoren: ITEd
Ladezeit der Seite: 0.148 Sekunden
Donation Image