tags within html editor

tags within html editor

by Cory Gordon -
Number of replies: 5

Hi People!

Moodle V. 1.9. being used here.

I'm wanting to use form tags within the topic section in my moodle frontpage. However when I type the code into the html editor (I'm using tinyMCE 3) and click save, the form tags are stripped.

I've gone through the forums and they've talked about changing the security function trustedcontent. I've made sure this is selected for admin users, but this doesn't seem to have any effect.

Does anyone have any ideas on how I can sort this out?

thanks,
Cory

Average of ratings: -
In reply to Cory Gordon

Re: tags within html editor

by Devin Roush -

Cory,

Your problem sounds somewhat similar to the one I am having.  Only, instead of "form" tags being stripped, the "src" attribute is being stripped from images I insert via the HTML editor.  Very bizzare.

I'm still working on a solution.  You might go ahead and check out my forum (http://moodle.org/mod/forum/discuss.php?d=97565) as one of the suggestions that hasn't worked yet for me might work for you?

In reply to Devin Roush

Re: tags within html editor

by Cory Gordon -

Hi Devin

Thanks for replying...nothing in your lot seems to shed any light on my situation...*bummer*

Thanks though,
Cory

In reply to Devin Roush

Re: tags within html editor

by Paul Ortman -
I ran across this when searching for why src attributes of image tags were being stripped from view in wiki pages. I found a bug in the tracker: MDL-14372 where it was reported and a work around given (lowercase the image file name).
In reply to Cory Gordon

Re: tags within html editor

by Mauno Korpelainen -

Hi Gory,

maybe it has something to do with the init code of your tinymce. I tested inserting form tags to topic section with my editor test package and it works ok. Some activities may strip tags according to settings of allowed tags in weblib.php (filters of moodle) but this should not happen in topic section.

Check http://wiki.moxiecode.com/index.php/TinyMCE:Configuration/valid_elements

If no valid_elements tag is defined in init code tinymce should use default set of elements and allow form tags. I have used full XHTML rule set and it allows form tags as well.

In reply to Mauno Korpelainen

Re: tags within html editor

by Cory Gordon -

Hi Mauno!

Thanks for your reply! I just went through the tinyMCE documentation and it includes FORMS there, so that could be the way to go.

How do I go about changing the tinyMCE configuration to use the full XHTML rule set? I'm looking, but can't see where this is entered? Where is the init code?

thanks,
Cory