SearchSelectionElement

  •  01-10-2014, 12:35 PM

    SearchSelectionElement

    Hi

     

    Using the previous editor we had the following code.... This enabled us to detect if the selected object was an image, then we could extract various parameters. We used this a lot before to detect images, divs etc. Is there something similar using this new editor? 

     

    function getImageResizeURL() {
    // get the cute editor instance
    var editor1 = document.getElementById('ctl00_maincontent_Editor1');
    var oIMG = editor1.SearchSelectionElement('IMG');

    //If selected item is a image
    if (oIMG != null) {
      return oIMG.src;
    }
    return '';
    }

     

    Hope you can help.

     

View Complete Thread