hey,
i calling this file via ajax:
but for some reason it's not replacing the textarea...
any ideas?
Thanks!
i calling this file via ajax:
<?php
header('Content-Type: text/html; charset=windows-1255');
session_start();
$q = mysql_query("SELECT * FROM pages WHERE lang='".$_SESSION['lang']."' AND page='main_page'") or die(mysql_error());
$r = mysql_fetch_array($q);
?>
<script type="text/javascript" src="../editor/ckeditor.js"></script>
<script src="../editor/sample.js" type="text/javascript"></script>
<link href="../editor/sample.css" rel="stylesheet" type="text/css" />
<h3>עמוד ראשי</h3>
<form method="post" action="index.php?act=main_page">
<table width="100%" cellpadding="3" cellspacing="0" border="0">
<tr>
<td><textarea name="content" id="content" cols="70" rows="10"><?php echo $r['content']; ?></textarea></td>
</tr>
</table>
<div style="margin-right: 98px;"><input type="submit" value="אישור"/></div>
<div style="text-align: center;"><a href="#" onclick="hide_block('blank');">סגור</a></div>
</form>
<script type="text/javascript">
//<![CDATA[
CKEDITOR.replace( 'content' );
//]]>
</script>but for some reason it's not replacing the textarea...
any ideas?
Thanks!

Re: load ckeditor in file called by ajax
Re: load ckeditor in file called by ajax
the the editor located in the main directory with the index file, the main_page.php (the file i call with ajax) locateded in the ajax directory, so the path should be ../editor
Re: load ckeditor in file called by ajax
when i open this file alone (without ajax) the editor works fine!
Re: load ckeditor in file called by ajax
Try to replace textarea in the "Load" method of the body element.