Hello, im trying to manupilate fck editor from the outside, I got images on the left of the editor and I want my users to be able to insert the image in the editor onclick.
I had this working with a normal textfield, with this function:
function areapic (picture)
{
document.post.message.value = document.post.message.value + " " + '<img src="' + picture + '" border="0" /> ';
}
anyone any idea how to achieve this using the fckeditor?
thanks a LOT!
Thomas
I had this working with a normal textfield, with this function:
function areapic (picture)
{
document.post.message.value = document.post.message.value + " " + '<img src="' + picture + '" border="0" /> ';
}
anyone any idea how to achieve this using the fckeditor?
thanks a LOT!
Thomas
RE: manupilating fckeditor from the outside
Which version of the editor are u using? PHP? JS?
i also tried something similar but couldnt get it to work. Any help guys? Really need to get this to work. The FCK <textarea> doesnt seem to allow outside events to change it.
There must be a solution!
Bio
RE: manupilating fckeditor from the outside
If you included a jsp you have full access to all methods of the fckeditor. For example you can call the java script function "insertHtml('hello world')" to add text into the fck-textarea.
The second reason for me to work with an include was, that you can show the include and a "normal" textarea if the browser isn't compatible. In this case your java script functions have to check if they browser is compatible and the fck-insert-functions should be called or not so using your own java script functions to add text into a normal textarea.
Gruss aus Ravensburg (Germany)