im looking to assign an id to the textarea to pull in an ajax query to populate the textarea from the database, looking through the Docs for CKeditor i come across this
so i added this line to config.js (which i suppose is where it goes as the docs point to no example)
but as it is it is not pulling the created id into the text area, did i add it to the right place, also ckeditor version is 3.2 thanks
EDIT i noticed that on the Docs page right at the top is a referance to core/config.js which contains config.bodyId = '' i have now populated this with the id i wish to assign and still nothing is showing when viewing the source code
<static> {String} CKEDITOR.config.bodyId Since: 3.1 Sets the "id" attribute to be used on the body element of the editing area. NO EXAMPLE AVAILABLE Default Value: ''
so i added this line to config.js (which i suppose is where it goes as the docs point to no example)
config.bodyId = 'content';
but as it is it is not pulling the created id into the text area, did i add it to the right place, also ckeditor version is 3.2 thanks
EDIT i noticed that on the Docs page right at the top is a referance to core/config.js which contains config.bodyId = '' i have now populated this with the id i wish to assign and still nothing is showing when viewing the source code
Re: Assign id to textarea
Have you tried to populate just the textarea, without enabling ckeditor? If that works, then make sure that the textarea is populated with the content before running the ckeditor init. Since ckeditor replaces the textarea with it's own elements, the textarea maybe isn't around when your ajax tries to fill it up.
Just an idea... Haven't tested it.
/Peter
Re: Assign id to textarea
and yes Petera you are correct, it could well be something to do with when ajax or ckeditor fires as when i use a plain html textarea with no instance initiated the area loads fine with my database content, so my next question is what do (or can ) i do to get around this?