html - What is a work around for displaying empty <p> tags inside contenteditable div? -
this internet explorer only.
have content editable div in users enter rich content (niceditor).
i have functionality set html of div predefined templates. ideally templates like.
<p><b>my heading1</b></p> <p></p> <p></p> <p><b>my heading2</b></p> <p></p> <p></p> <p><b>my heading3</b></p> <p></p> <p></p>
where renders
my heading1
blankline
blankline
my heading2
blankline
blankline
my heading3
blankline
blankline
however renders so.
my heading1
my heading2
my heading3
i've tried using these instead there issues of them.
<p> </p>
, <p><span style="display:none;"> </span></p>
- space on each line.
<p><br/></p>
- when user starts typing new line appears.
<br/>
, <span><br/></span>
- works spacing except when user uses 1 of insert list commands. , content put under single list item.
what can have <p>
tags display in div?
i have had success in using <p>​</p>
0 width space character. however, makes if user wishes delete line must press backspace twice. i'm going ask new question address that.
here
Comments
Post a Comment