Chcę aby FCKeditor po kliknięciu przycisku, zapisywał mi dane do pliczku (a potem z niego czytał). Zrobiłem coś takiego, ale mam wielki problem.
Ale głównie chodzi o to, gdy załamię linię w pliku glowna.html to nie wyświetla się skrypt, wszystko musi być w jednej lini. A mój drugi skrypcik zapisuje wszystko tak jak się wyświetli...

Kod
    <form action="edit_index2.php" method="post">
        <script type="text/javascript">
<!--
// Automatically calculates the editor base path based on the _samples directory.
// This is usefull only for these samples. A real application should use something like this:
// oFCKeditor.BasePath = 'fckeditor/';    // 'fckeditor/' is the default value.
var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples'));

var oFCKeditor = new FCKeditor( 'FCKeditor1' );
oFCKeditor.BasePath    = sBasePath = 'fckeditor/';
oFCKeditor.Height    = 500;
oFCKeditor.Value    = '<?php require_once('../../glowna.html'); ?>';
oFCKeditor.Create();
//-->
        </script>
        <br />
        <input type="submit" value="Submit" />
    </form>

Wyświetla się w nim FCKeditor. Za wyświetlanie w nim danych odpowiada to:
Kod
oFCKeditor.Value    = '<?php require_once('../../glowna.html'); ?>';

Czyta z pliku glowna.html

Ok wszystko dobrze gdy w pliku glowna.html kod jest zapisany tak:
Kod
<b>dasdasda</b>dfasdasda cos tam

ale gdy jest tak:
Kod
<b>dasdasda</b>
dfasdasda cos
tam

To nie wyświetla się edytor (na js sie w ogole nie znam o_O)