Quantcast
Channel: Telerik Forums RSS
Viewing all articles
Browse latest Browse all 94857

Editor - Generate Unique Id for sub elements

$
0
0

Hi,

I'm trying to generate a unique Id for each sub element within an inline editor using the change event on the editor:

 

change: function () {

    $(editor).children().each(function (index, element) {
           $(this).uniqueId();
     });
}

 

This works well, except that I noticed that when I insert a new paragraph, the Kendo editor clones the previous paragraph including the id attribute, which results in duplicate Ids!

 Is there a way to override the cloning behavior in the editor? Intercept it to remove the id attribute from the newly inserted node?

 

Thanks,

Mohammad


Viewing all articles
Browse latest Browse all 94857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>