I've developped a module which uses tinymce. In my database, I store text in html-format. For example line1line2
I want to display this html-text in a tinymce editor, but I always see the html completely, including the html-tags.
I use the function 'CreateTextArea' to display the textarea.
MyModule::CreateTextArea(true,$id,$myText,"txtMyText");
--> where $myText contains "line1line2"
I'm doing something wrong, but I don't know what...
html in tinymce
Re: html in tinymce
Most likely your problem is you are calling a text area not tiny so of course your only going to get raw code...
Re: html in tinymce
If you look at that in raw html mode does it have the in html entities?...
Re: html in tinymce
If I look at it in raw-mode it is the content of the editor is : line 1
line 2 And that is exactly what is stored in my database
If I switch to html-mode it is <p>line 1<br />line 2</p>
My settings are set to "raw encoding"
line 2 And that is exactly what is stored in my database
If I switch to html-mode it is <p>line 1<br />line 2</p>
My settings are set to "raw encoding"
Re: html in tinymce
The <p>line 1<br />line 2</p> is why when you look at it in tiny or on a page it looks like line 1
line 2 somewhere between where you put it and tiny getting it it is changed into html entities...
line 2 somewhere between where you put it and tiny getting it it is changed into html entities...