#1464: Unable to create <p> inside <div> (the return)
-----------------------------+----------------------------------------------
Reporter: designstack | Owner:
Type: Bug | Status: closed
Priority: Normal | Milestone:
Component: UI : Enter Key | Version: FCKeditor 2.5 Beta
Resolution: fixed | Keywords: Confirmed
-----------------------------+----------------------------------------------
Changes (by fredck):
* keywords: Discussion => Confirmed
* status: new => closed
* resolution: => fixed
Comment:
Replying to [comment:2 designstack]:
> '''If people want a <div> to behave like a <p> then this could be
accommodated by''' setting the EnterMode to 'div' or '''applying it
manually using the 'Format' dropdown menu'''.
This is the key to understand the current behavior. Right now, the only
way to produce {{{<div>abc</div>}}} with the editor is by using the Format
combo. By doing that the user is saying that that {{{<div>}}} is a
"paragraph", and that s/he wants it to behave like that, which currently
means duplicating itself on ENTER.
Another thing to consider is the definition of {{{<div>}}} in the HTML5. A
{{{<div>}}} as a container '''cannot''' contain text or inline elements.
It can only contain block elements. So, we are assuming that
{{{<div>abc</div>}}} is not a container, and the assumption is correct.
Now, the only way to make users confused is by inputting code not produced
with FCKeditor. Alfonso exemplified it with templates. In this case, the
template itself is wrong. It must not contain an {{{<div>Type
here</div>}}} tag to indicate that you want a container there. It must
instead have {{{<div><p>Type here</p></div>}}}, so the template designer
intention is clear.
To create container divs instead, we just came out with the Div Container
Tool. So, if you want a {{{<p>}}} inside a {{{<div>}}}, then just use that
tool over your {{{p}}} and you will have it done. I'm closing this ticket
as we already have a way to do that.
We can still open a discussion over the {{{<div>}}} support for V3, but
this ticket is not the right place for that. I would suggest going to the
[http://www.fckeditor.net/forums/viewforum.php?f=11 ODE Forum] for it.
--
Ticket URL: <http://dev.fckeditor.net/ticket/1464#comment:6>
FCKeditor <http://www.fckeditor.net/>
The text editor for Internet
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
FCKeditor-Trac mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fckeditor-trac