Re: PasteHTML not working correctly

  •  04-19-2007, 10:24 PM

    Re: PasteHTML not working correctly

    My Javascript code follows.   The PasteHTML puts the string at the beginning of the editor's content, regardless of the original position of 'selectedhtml'
     
     
    var editor1 = document.getElementById('');
    var editor1doc = editor1.GetDocument();
    var selectedhtml = editor1doc.selection.createRange().htmlText;
    editor1.PasteHTML("**BEFORESELECTION**" + selectedhtml + "**AFTERSELECTION**");
View Complete Thread