Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

inject the editor some where else

#11

Hi all,

i have a little problem with injecting the editor somewhere else in the dom
example code:

<div class="source">

&lt;div class=&quot;editor-container&quot;&gt;
    &lt;textarea class=&quot;editor&quot;&gt;&lt;/textarea&gt;
&lt;/div&gt;



</div> <div class="target"></div> <div class="button">inject bottom to top</div> <script type="text/javascript">
window.addEvent('domready', function () {
    new MooEditable(document.getElement('textarea'));

    document.getElement('div.button').addEvent('mouseup', function () {
        document.getElement('div.editor-container').inject(document.getElement('div.target'));
    });
});



</script>
the error message is:

uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) nsIDOMNSHTMLDocument.execCommand]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: http://dev/html/js/MooEditable.js :: anonymous :: line 400" data: no]

someone of you got an idea how to solve it? perhaps a re-render or sth like this ?

best regards
georg

Reported by schelmo · September 18th, 2009 @ 06:10 AM

State: invalid
Milestone: 0.5
Assigned to: Lim Chee Aun Lim Chee Aun

Activity

  1. schelmo
    schelmo

    okey kust found the attach/detach methods. works now.
    thx anyway :)

    September 18th, 2009 @ 06:23 AM

  2. Lim Chee Aun
    Lim Chee Aun
    • State changed from new to invalid

    November 7th, 2009 @ 07:39 AM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.