Editor: Formatting

Topics: General
Apr 20, 2011 at 9:22 AM

Hi everyone,

Hopefully someone has had a similar problem.

I posted a question on TinyMCE's forum regarding the formatting of text within the editor but they feel it's specific to Composite's version of the editor.

I added a new formatting option to the advancedtoolbar, called CustomLayer which renders text wrapped in a <div /> instead of a <p />. However, I need text, within this wrapper to be additionally formatted with the predefined formatting rules, H1, H2, H3 and paragraph, however, when I select additional text and formats, it transforms my container into the selected formatting option, instead of appending the new format to the text selected.

Has anyone else run into this problem of have a possible solution for me?

I'm using the 4 browsers in their latest releases, have not tested this on anything less.



Apr 20, 2011 at 1:58 PM

I suppose this is TinyMCE issue.

Elements such as  H1, H2, H3 have BLOCK format
Configuration:formats  page contains  summary for the block format:
block - Name of the block element to produce for example "h1". Existing block elements within the selection gets replaced with the new block element.

So if you select some text within block element and will try so apply new block element, existing block element will be replaced with new one.

The same behavior you can reproduce at the TinyMCE Demo page.