Problems with saving code in HTML editor

Problems with saving code in HTML editor

by Joe Ross -
Number of replies: 1
Hi all,

I've been having difficultly using the html editior in moodle since our recent upgrade to 1.9.

Currently when we make changes to html code located in resources such as labels the code is modified on an inconsistent basis when ever we save the changes in the html editor.

For example i can type the following into the html editor:

<iframe width="100%" height="200" align="middle" src="http://www.sitepoint.com" border="0"></iframe>

I then click save and view, sometimes it works fine, other times i get something like this:

<iframe width=\"100%\" height=\"200\" align=\"middle\" src=\"http://www.sitepoint.com\" border=\"0\"></iframe>

I have tried various settings in in the HTML editor to remove these garbarge characters from being added including using the clean formatting option. Usually the problem involves the insertion of slashes into the html code.

Does anyone know why this is happening, what I can do to fix it, or potential work arounds for this problem. We did not have issues with this in our previous version of moodle 1.7 but these problems have begun to occur since we upgraded to moodle 1.9. Any help or advice would be appreciated.

Thanks.
Average of ratings: -
In reply to Joe Ross

Re: Problems with saving code in HTML editor

by Bill Mounce -
The slashes are probably there because you are using the double quote marks. I forget the name for this but without the slash php will misinterpret the double quote marks. I think you need them. Does it actually change the functionality of your code?