marcusgreen / moodle-qtype_wordselect

langHighlight words by clicking e.g. select all nouns in this sentence
2 stars 10 forks source link

Word Select is not marking correct answers as correct for Students #27

Closed valeriia-s closed 4 years ago

valeriia-s commented 4 years ago

Hi @marcusgreen,

We are using the latest plugin version on Moodle 3.7. After the last version was released, we discovered the following issue.

While Word Select allows students to select an answer(s), it is not marking those that are correct, as correct. This issue happens only with the questions 1 and 3 that have additional HTML added to them (like <br> or &nbsp;).

Here is how the question 1 looks like when I open an HTML editor (it has
tags): ​​

2020-02-28_1429

[John Smith]<br> [Jane Smith]<br> John Smith, Jr.<br>[Sally Smith]<br>

Here is my updated version - question 2 (without additional HTML):

2020-02-28_1434

<p>[John Smith]</p><p>[Jane Smith]</p><p>John Smith, Jr</p><p>[Sally Smith]</p>

Here is how the 3 question looks like when I open an HTML editor:

2020-02-28_1503

<p>Select the car that Sally Smith is allowed to drive under the policy.</p><p>&nbsp;Porsche</p><p>&nbsp;Mercedes</p><p>&nbsp;[Cabriolet]<br></p>

Here is my updated version - question 4 (without additional HTML):

2020-02-28_15032

<p>Select the car that Sally Smith is allowed to drive under the policy.</p><p>Porsche</p<p>Mercedes</p><p>[Cabriolet]</p>

When an Admin attempts this quiz, Word Select works as it should. Even with the additional HTML tags added:

2020-02-28_1511

However, here is what the Student role gets:

2020-02-28_1512

The text looks the same visually, however, the main difference is in HTML. The text was probably copied from an external editor and pasted into the Moodle Atto editor.

Please let me know if you need more details.

Thank you, Valeriia

marcusgreen commented 4 years ago

Thank you for the detailed description. I will investigate.

marcusgreen commented 4 years ago

Closing this issue. Release 2.43 included a fix for this which is documented in the release notes. Thanks for reporting this. https://github.com/marcusgreen/moodle-qtype_wordselect/blob/master/changelog.md