I am using FCKEditor for an article submission area on my web site. I am trying to implement a preview button so the user can preview his/her article before posting it.
I have all this set up fine. When the user clicks on the preview button it simply posts the form data to the script page which shows a preview of the article as well as the FCKEditor so they can make the changes. In order to get the articles content I am using $oFCKeditor->Value = $_POST[content]; to pull it back into the editor...
But its not working - If for example I aligned some text to the right and previewed it - it would display correctly in the preview area (this is just echoing from $_POST) but loses formatting in the editor.
How can I get around this?
Thanks
I have all this set up fine. When the user clicks on the preview button it simply posts the form data to the script page which shows a preview of the article as well as the FCKEditor so they can make the changes. In order to get the articles content I am using $oFCKeditor->Value = $_POST[content]; to pull it back into the editor...
But its not working - If for example I aligned some text to the right and previewed it - it would display correctly in the preview area (this is just echoing from $_POST) but loses formatting in the editor.
How can I get around this?
Thanks
Re: Post to the editor - losing formatting