﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
10117	Inline editing does not apply to elements created on the fly	Dries Geris		"Hi,

The new inline editing feature is fantastic.
It works great when a page is rendered with content and you set the attribute contenteditable=""true"" for specific elements.

But if you create a new element on the fly, after the page was rendered, it seems that the toolbar is not shown.

Example :

{{{
function addBox(){
  var divID = new Date().getTime()
  var divIdName = ""block_""+divID;
  var newdiv = document.createElement('div');
  newdiv.setAttribute(""id"", divIdName);
  newdiv.setAttribute(""contenteditable"", ""true"");
  newdiv.innerHTML = ""editable data"";
  document.getElementById(""parent_container"").appendChild(newdiv);
}
}}}

In the body section of the page there's a div called ""parent_container"" and the new elements are appended to that container

<body onload=""addBox();"">
<div id=""parent_container"" name=""parent_container""></div>
</body>

In the above example, I give the new element the attribute contenteditable=true and indeed, the content is editable, but no toolbar.
I know that in this case I could call ""CKEDITOR.inline( divIdName );"" in the function and in that case it will work.

But what if in the addBox function, I don't set the new div as being editable, but the inner concent of that new div has elements that are editable.


example : 

{{{
function addBox(){
  var divID = new Date().getTime()
  var divIdName = ""block_""+divID;
  var newdiv = document.createElement('div');
  newdiv.setAttribute(""id"", divIdName);
  newdiv.innerHTML = ""<div class='titleBoxWrapper'><div class='titleBoxHeaderTitleWrapper'><div class='titleBoxHeaderIcon'><img src='' /></div><div class='titleBoxHeaderTitle' contenteditable='true'>header title</div></div><div class='titleBoxContent' contenteditable='true'>new box</div></div>"";
document.getElementById(""parent_container"").appendChild(newdiv);
}
}}}

In this example, I cannot call CKEDITOR.inline( divIdName ) as that would make the outer div editable and that is not want I want. The new div has inner elmenents that are editable, but these elements don't have an ID as in real life, the inner content of the new element is loaded from templates and therefore the content is general, without ID's. Only the outer div, into where the template is loaded, get's an ID.

Is there a reason why the toolbar is not shown on all elements having contenteditable=""true"" when they are created after the page was rendered?"	Bug	closed	Normal		Core : Editable	4.0.1	invalid		
