ignore punctuation and case

  • teacherjonny
  • Onderwerp Auteur
  • Offline
  • Senior lid
  • Senior lid
Meer
4 jaren 7 maanden geleden #7826 door teacherjonny
ignore punctuation and case werd gestart door teacherjonny
Hello All,
I am using interaction >dialog where I have a prompt and the student is asked to type in a response. Is there a way to ask xerte to ignore any punctuation in the student's response and to change any upper case letters to lower case? Is there a way to learn the name of the variable that contains the student response and then use java script to do the above?
Thanks!

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

Meer
4 jaren 6 maanden geleden #7830 door Fay
Beantwoord door Fay in topic ignore punctuation and case
The dialogue page is not case sensitive by default so when it checks the student answer against the correct answer it will change both to lowercase (you can add the case sensitive optional property to force the case to be checked too). There's no built in easy way to remove punctuation from the student's answer though. If you want to add custom code to the page to deal with this then it's likely to be a bit fiddly - start by looking at the model for the page so you can see what's currently happening. The submit button code that checks correct answers is around line 143 in this file: Dialogue model file
De volgende gebruiker (s) zei dank u: teacherjonny

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

  • teacherjonny
  • Onderwerp Auteur
  • Offline
  • Senior lid
  • Senior lid
Meer
4 jaren 6 maanden geleden #7838 door teacherjonny
Beantwoord door teacherjonny in topic ignore punctuation and case
Thank you very much. I appreciate the response and I'll try to write something. I didn't realize that I had access to the model files. How can I learn the location of other files? I would like to learn if it's possible to test one of my corrections in an exercise, for example in item 8 without having to go through all of the items until I reach 8. Can't I "run from 8" for example.

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

Meer
4 jaren 6 maanden geleden #7839 door tom
Beantwoord door tom in topic ignore punctuation and case
If with "item" you mean page, yes you can. Just press the Shift key when pushing the preview/play button.
De volgende gebruiker (s) zei dank u: teacherjonny

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

  • teacherjonny
  • Onderwerp Auteur
  • Offline
  • Senior lid
  • Senior lid
Meer
4 jaren 6 maanden geleden #7859 door teacherjonny
Beantwoord door teacherjonny in topic ignore punctuation and case
OK I can write code in Javascript to remove punctuation and space between words. But how do I find the code for the "interactivity, dialog" to modify it on my server? What is the name of that 'module" In other words, where is the code on my server that you directed me to on github? While the present xerte code that converts both the correct answer and the student input to lower case is welcome, the students are upset when they have their answers declared wrong because of a discrepancy involving a comma, or another punctuation mark, or an inadvertent extra space. I'd like to fix this.
Thanks.

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

Meer
4 jaren 6 maanden geleden - 4 jaren 6 maanden geleden #7861 door Fay
Beantwoord door Fay in topic ignore punctuation and case
The files for all the page types are in this folder: modules/xerte/parent_templates/Nottingham/models_html5
If you edit any of the core Xerte files you need to remember that your changes will be lost if you later upgrade. We generally don't recommend editing them for this reason
Laatst bewerkt 4 jaren 6 maanden geleden door Fay.
De volgende gebruiker (s) zei dank u: teacherjonny

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

Moderators: ronmalimcn
Tijd voor maken pagina: 0.231 seconden
Copyright © 2026 The Xerte Project.
Xerte logo Apereo logo OSI Logo