Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-37223

Limit textual input on short answer questions via JavaScript

    XMLWordPrintable

    Details

    • Type: (Deprecated) Contributed Patch
    • Status: CLOSED
    • Priority: Major
    • Resolution: Incorporated
    • Affects Version/s: 2.6.0, 2.6.1, 2.6.2
    • Fix Version/s: 2.6.x, 2.6.3
    • Labels:
      None
    • Previous Issue Keys:
      SAM-920

      Description

      Scenario:
      1) Creates a new "Timed test"
      2) Creates a question type "Short Answer/Essay"
      3) Go to settings
      4) Sets "Timed assesments" to "6 min"
      5) Logs in as student and starts the test
      6) The field indicates a maximum of 4000 characters
      7) A string of 10 000 characters is entered.
      8) No warning.
      9) Wait for time to pass
      10) When time is up a messages says: "Time is up and your answer has automatically been handed in".
      11) I click "OK"
      12) Errormessage: "Validation Error: Value is greater than allowable maximum of '4,000' "
      13) Test seems to be starting over. TImer starts at 6 min.
      14) All 10 000 characters are still in the text-field.
      15) Try clicking the submit-button again. Same thing again. Time starts over.
      16) Edit the text in the field to 4000 characters.
      17) When times up you get the times-up-handed-in-automatically-answer again
      18) Then an errormessage that there might be problems with the submitted data.
      19) Log in as teacher again.
      20) The handed in answer is blank

      SOLUTION: Limit input of ShortAnswer to 4000 with javascript. Nothing more can entered either by pasting or writing!

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                samigoteam SAMIGO TEAM (Inactive)
                Reporter:
                jan.bidner@ladok.umu.se Johan Carlsson (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Git Source Code