data-editor-template in self-closing DIV
data-editor-template in self-closing DIV
boni.m
Posts: 3Questions: 2Answers: 0
Hello,
using data-editor-template attribute with self-closing DIV (see https://editor.datatables.net/manual/templates ) doesn't work:
<fieldset class="hr">
<legend>HR info</legend>
<div data-editor-template="position"/>
<div data-editor-template="salary"/>
<div data-editor-template="start_date"/>
</fieldset>
leads to nested DIVs:
<fieldset class="hr">
<legend>HR info</legend>
<div data-editor-template="position">
<div data-editor-template="salary">
<div data-editor-template="start_date">
...
</div>
</div>
</div>
</fieldset>
You have to use DIVs with start and end tags (like here: https://editor.datatables.net/examples/simple/template-attribute.html ) to get proper results:
<fieldset class="hr">
<legend>HR info</legend>
<div data-editor-template="position"></div>
<div data-editor-template="salary"></div>
<div data-editor-template="start_date"></div>
</fieldset>
This discussion has been closed.
Answers
Thanks for posting this. I'll look into what is causing that. I remember a bug with an older version of Editor which had that effect, but it shouldn't happen in the current 1.6.3 release.
Allan