Advanced HTML Editor 3 Support Product Page

How can I change the content of the editor with ajax?

Reported 26 Apr 2012 13:54:16
1
has this problem
26 Apr 2012 13:54:16 Bernd Schmitt posted:
My problem: I have to change the content of the editor area without submitting the form. There is a pulldown menu to load various contents in the editor field. This should be done with jquery ajax.

Here my request script:

$.post("ajax.script.php", { id: id }, function(requestData){

// what is to do here?
$("#textarea_id".data('dmxEditor').save();
//

});

I need a kind of << $("#textarea_id".data('dmxEditor').save(requestData) >>
Is there a solution?

Replies

Replied 26 Apr 2012 13:57:32
26 Apr 2012 13:57:32 Bernd Schmitt replied:
Postscript:

My debugger says:
Error:
$("#textaria_id").data("dmxEditor").save() is undefined



After replacing the ajax script from the document.ready function in the main javascript to beneath the dmxEditor config script, the error is gone. But the data loading still not work.
Replied 27 Apr 2012 10:00:44
27 Apr 2012 10:00:44 Bernd Schmitt replied:
No answer?
Maybe I have not written clearly enough, my english is not so good.

What I need, is a function to load new content in the editor on the fly without sending the form AND without saving the data.

What I have is a request from a jquery $.get() or $.post() function that must be loaded into the editor.

Welcome would be a documentation of the api.
Replied 27 Apr 2012 13:01:45
27 Apr 2012 13:01:45 Teodor Kuduschiev replied:
Hello Bernd,

Unfortunately this idea is not possible.

Reply to this topic