You are not logged in.
Pages: 1
Hi there,
I have the following problem:
The contents of my page are all created using ajax-requests.
I have added xinha to my page as the newbie guide says, the plugins and the core get loaded correctly but the textarea I want to use as an editor is not transformed as expected.
When I use the same code outside of the head and load it within the ajax-request, everythings works fine the first time, but when I fire the ajax a second time, it does not work anymore.
The third thing I tried was to only call xinha_init() within the ajax and leave the rest in the head (which is only loaded once), but still, it only works the first time, the second time i call the contents, the textarea remains unchanged.
Does anyone know what I could do here?
Thanks!
Offline
I expect you'll need to create your own initialisation routine, the example "xinha_init" won't be for you. Read the function, see what it does, and write your own to do what you need when you need it.
Read these methods:
Xinha.makeEditors
Xinha.startEditors
in the XinhaCore.js
At a minimum, you need to create a Xinha object and then call generate on it
var ed = new Xinha(your_textarea, your_xinha_config);
ed.generate();
James Sleeman
Offline
Pages: 1