Lesson Module and HTML Editor

Lesson Module and HTML Editor

by Steven Roberts -
Number of replies: 13

Hello

We are a LEA who use Moodle for collaboration between 8 senior comprehensive schools.

We have started to look at the Lesson Module and think it could be very useful.

The problem we have is:
When we create a question the Html Editor is available for the question text.
In the Answer 1: box we have the following [Use editor: answereditor[0].
In the Response 1: box we have the following [Use editor: responseeditor[0].

When the option is ticked the Html Editor is still not available for the Answer 1 or Response 1 box, either when the page is Redisplayed or the page is Saved and then reloaded.

Also the [ ] square brackets and the text answereditor[0] responseeditor[0] look untidy.

Can anyone help

Many Thanks

Steve Roberts

Average of ratings: -
In reply to Steven Roberts

Re: Lesson Module and HTML Editor

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi Steven!

Before providing help we need to know the following details:

a) which version of Moodle are you using: Moodle 1.5.3stable or 1.6dev?
b) which type of question are you talking about: MCQ, short answer, TRUE/FALSE, etc.

For instance you write:

In the Answer 1: box we have the following [Use editor: answereditor[0].
In the Response 1: box we have the following [Use editor: responseeditor[0].

In Moodle 1.5.3stable and 1.6dev I cannot see this, but (see screen shot below).

Joseph

Attachment Image1.jpg
In reply to Joseph Rézeau

Re: Lesson Module and HTML Editor

by Steven Roberts -

Hello Joseph

a) which version of Moodle are you using: Moodle 1.5.3stable or 1.6dev?
We are using 1.5.3stable
Also the latest Lesson Module Download.
b) which type of question are you talking about: MCQ, short answer, TRUE/FALSE, etc.
The type of question is Multi Choice Question.

Please see attached jpeg image.

Many thanks

Steve

 

Attachment Lesson.jpg
In reply to Steven Roberts

Re: Lesson Module and HTML Editor

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hmmm > We are using 1.5.3stable; Also the latest Lesson Module Download.

Do you mean that, using 1.5.3stable, you went to this download page : http://download.moodle.org/modules/ and, under Module/Lesson you clicked on Latest and used the lesson.zip contents to overwrite the lesson module files in your installed Moodle 1.5.3stable?

If you did this, it was a mistake and it is the cause of your problem.sad

It is very unfortunate that is is not clearly indicated on that download page that Latest means latest version of the module for the 1.6dev version.

If you had wanted to dowload the latest version of a module for your current 1.5.3stable version, then you should have clicked on Lesson module 1.5.x link!

However, there is indeed something wrong with the availability of the HTML editor in the editing question pages part of the Lesson module, and I am posting another message in this thread about it.

All the best,

Joseph

In reply to Joseph Rézeau

Re: Lesson Module and HTML Editor

by Steven Roberts -

Hello Joseph

I have removed the latest Lesson Module and replaced it with the latest Lesson module 1.5.x. The HTML editor is now available for the Answers and Responces. But we still have the [ ] [Use Editor: Answereditor[0]] and [Use Editor: Responseeditor[0]].

It is not a problem but looks untidy.

Many thanks for your help

Steve Roberts

In reply to Steven Roberts

Re: Lesson Module and HTML Editor

by Mark Nielsen -
The style sheet is not working for your lesson module.  Try looking in your theme's config.php file and make sure you see the following line:

$THEME->modsheets = true;

If it is false, change it to true and it should fix your problem.

Cheers,
Mark
In reply to Steven Roberts

Re: Lesson Module and HTML Editor

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
There is definitely something wrong in the availability of the HTML editor in the Lesson module when editing question pages.
Moodle 1.5.3stable
Create a new question page (call it TEst1)
HTML is available for Page contents, not available for Answer or Response boxes.
default question type is MCQ, leave it like that
Question = What do you think of Moodle?
Answer 1 = Moodle is nice
Response 1 = this is ok
Answer = Moodle is bad
Answer 2 = wrong
There are no tick boxes to ask for HML editor in Answers or Responses
Save (Button Add a Question Page)
Now edit that TEst1 question page (click on Update icon/link)
Tick the Use editor boxes in Answer 1, Response 1, etc.
At the bottom of page, click on the Redisplay page button
Now the HTML editor is available
Format some of the text for Answer/Response 1, e.g. Moodle is nice, this is ok
Save
Check question
Formatting has been preserved both in Answer choices and in feedback to student. Fine.

Now, change our Test1 question page from MCQ type to Short Answer type. Edit it and in the question type tabs click on Short Answer, then save.
Check question page Test1
Question page is displayed as short answer format.
Enter 'Moodle is nice'
Response displayed = That's the wrong answer
Enter 'Moodle is <span style="font-weight: bold;">nice</span><br />'
Response displayed = this is ok
Problem: obviously it should not be possible/allowed to use the HTML editor when editing the Answer box of short answer questions, as this interferes with the student's answer analysis...
Moodle 1.6dev
Curiously, in this version, HTML editor has been totally removed from question page editing.
However, the tick boxes are still there, but without effect, i.e. if you tick Use editor, then Redisplay page, nothing has changed.
This is going too far.
What should be done (in both versions)
Allow/Enable HTML editor for all question types and all answers and responses except for:
short answer type, Answer box
numerical type, Answer box

I have posted bug report #4852

Joseph

In reply to Joseph Rézeau

Re: Lesson Module and HTML Editor

by Michael Penney -
We should probably just take it out for editing answers as it causes lots of problems we don't have time to fixsad.

Actually, a big part of the solution would be to get lesson to use the quiz question categories and editors, unfortunatly we don't have the resources to do that right now.
In reply to Michael Penney

Re: Lesson Module and HTML Editor

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi Michael!

I think it would be a pity not to make the HTML editor available in the question types where it can be quite useful. For example in matching, the only way we can match pictures with names is by having the HTML editor available.

Is it that hard to simply spot in the program that we are editing either a short answer or a numerical and then remove the Answer x: [Use editor: and only in those cases? 

I quite agree that the way to go is to unify the lesson with the quiz. This has been asked for for a long time now; let's hope it will become a reality some time.

All the best,

Joseph

In reply to Joseph Rézeau

Re: Lesson Module and HTML Editor

by Michael Penney -
Hi Joseph, it probably wouldn't be too hard to do that, however it will take time, which we don't have the funds for right now.

In reply to Michael Penney

Re: Lesson Module and HTML Editor

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi Michael,

I have modified \moodle\mod\action\editpage to achieve the objectives explained in my previous post.

The HTML editor is now available everywhere when editing question pages *except* when editing short answers and numerical type questions where it is NOT available for the Answers editing.

I have posted this explanation and all the relevant files in bug #4825.

The modified file editpage.php works in 1.5.3stable as well as in current 1.6dev (see also attached editpage.php.diff, where DIFF is made against current 1.6dev file).

This file is all that is needed for my modifs to work in 1.5.3.

HOwever, in 1.6dev, file updatepage.php dated 13 Jan 2006 18:41:37 is different from same file in 1.5.3, with the result that the HTML editor is NOT AVAILABLE AT ALL when editing question pages. So I have reverted two lines to their 1.5.3 version in attached file updatepage.php. See updatepage.php.dif.

Please Michael and Mark, can you have a look at it and confirm that it's OK to use updatepage.php version 1.5.3 in version 1.6dev ?

Joseph

In reply to Joseph Rézeau

Re: Lesson Module and HTML Editor

by Mark Nielsen -
I'll take a look into this later this week and see what can be done.
In reply to Mark Nielsen

Re: Lesson Module and HTML Editor

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Thanks Mark,
Don't hesitate to contact me either in this thread or privately if needed regarding this matter,
Joseph
In reply to Joseph Rézeau

Re: Lesson Module and HTML Editor

by Mark Nielsen -
I took a gander at it today.  My response is in the bug tracker: bug #4852

Cheers and thanks,
Mark