Ticket #212 (closed Bug)

Opened 3 years ago

Last modified 3 years ago

Formatting actions inside document editor: allowed elements disappear

Reported by: andreas@… Owned by:
Priority: Minor Milestone:
Component: Version: 1.4
Keywords: Cc:

Description

[jira2trac import : issue created on November 17, 2005 6:56:43 AM CET http://issues.cocoondev.org/browse/DSY-212 ]

In order to allow custom tags, I modified htmlcleaner.xml:

<allowed-div-classes>
     <class>titlepage</class>
</allowed-div-classes>

Create a new document, switch to the HTML source editor and enter:

<html>
<body>
<div class="titlepage">
<h3>foo</h3>
</div>
</body>
</html>

I press the button "Cleanup HTML", the div-element is retained, everything is fine.

Now I switch to the HTML view.

I select the "foo" text marked as "H3" and set it back to "none".

Switch back to the html source view:

<html>
<body>
<p>foo</p>
</body>
</html>

The <div> element now is gone, for whatever reason.
Would be nice if allowed elements could be retained during any kind of formatting action inside the document editor.

Change History

comment:1 Changed 3 years ago by paul

  • Status changed from new to closed

[jira2trac import : comment created by bruno on November 17, 2005 9:21:53 AM CET]

There is nothing we can do about this, this behaviour is implemented in the browser-editing code (and could differ between browsers).

In addition, it is not really intended to do these sort of things in the Daisy-HTML editor, since:

  • it is not possible to create, and work with, these nested structures in the GUI editor
  • working with nested structures is often difficult for non-technical users (otherwise one might as well go for full-blown xml editing)

Depending on what you want to achieve, you could put the class directly on the header, work with multiple parts, use a custom part that doesn't use the HTML editor, ...

Note: See TracTickets for help on using tickets.