0
votes

If I use the debugger and look inside the tinymce iframe, I see my head information that as loaded. But when I call tinyMCE.activeEditor.getContent({format : 'raw'}), the head element comes back empty. I have added "fullpage" to the plugins as others have suggested.

It appears that tinymce is replacing the head element I gave it with its own and then dropping that before sending it back to me.

The problem is that I'm editing a complete HTML document and need teh head elements back.

Is this not possible with tinymce? Do I need different options in the .init()

1
Can you make a TinyMCE Fiddle showing your exact code and configuration of TinyMCE? Without seeing exactly what you are doing we will effectively be guessing how to help. stackoverflow.com/help/mcve - Michael Fromin
Here's my initialization: - mkeilhofer
I get a web page from the server using ajax and put it in a variable. Then I set the content like this: tinymce.activeEditor.setContent(contents, {format : 'raw'}); And though the variable 'contents' has the head elements, if I change nothing and then call tinyMCE.activeEditor.getContent({format : 'raw'}) the elements I originally saw in the head element are gone. - mkeilhofer

1 Answers

0
votes

Here is a Fiddle showing how this normally works:

http://fiddle.tinymce.com/3Bfaab

Note that the HEAD content is preserved so if you are not seeing it preserved its something tied to your specific setup.