[TYPO3-RTE] Automatic word clean?

Christopher Christopher at temporaryforwarding.com
Sat Nov 29 22:38:09 CET 2008


Hi Erik,

I have tested it now, but it does not work at all:

I read the following docs:
http://typo3.org/documentation/document-library/extension-manuals/rtehtmlarea/1.4.4/view/4/4/

http://typo3.org/documentation/document-library/references/doc_core_tsref/4.1.0/view/5/17/

And I saw a discussion in this newsgroup:
http://lists.netfielders.de/pipermail/typo3-project-rte/2008-August/001251.html
(The author also states that it does not seem to work correctly; but there 
is no solution.)


I am trying something like the follwoing at the moment, but it does not 
change anything:

RTE.default.proc.entryHTMLparser_db {
        noAttrib = b, i, u, strike, sub, sup
        # Remove if no attribs:
        rmTagIfNoAttrib = span, div, font

        tags {
                p.fixAttrib.align.unset >
                div.fixAttrib.align.unset >
                font.allowedAttribs = color, face, size
                p.allowedAttribs = class, style, align

                # PROBLEM: does not work
                h1.remap = b
                h2.remap = b
                h3.remap = b
                h4.remap = b
                h5.remap = b
                h6.remap = b
        }
}

...

RTE.default.enableWordClean = 1
RTE.default.enableWordClean.HTMLparser = 1
RTE.default.enableWordClean.HTMLparser < RTE.default.proc.entryHTMLparser_db
RTE.default.enableWordClean.HTMLparser {
                # HTMLparser config
                allowTags (
                        blockquote, b, br, caption, center, col, colgroup, 
div, em, h1, h2, h3, h4, h5, h6, hr, i, img, li, link, ol, p, pre, strong, 
table, thead, tbody, tfoot, td, th, tr, tt, ul, var )
                tags {
                        p {
                                # do not allow class.
                                allowedAttribs = id, title, dir, lang, 
xml:lang
                                fixAttrib.align.unset = 1
                                fixAttrib.style.unset = 1
                        }
                        # take away color, face, size
                        # Does NOT work.
                        font.allowedAttribs >
                        # Does NOT work either.
                        h1.remap = b
                        h2.remap = b
                        h3.remap = b
                        h4.remap = b
                        h5.remap = b
                }
                rmTagIfNoAttrib = span
                removeTags = u, o:p, font
        }
}

What can I do?

Christopher 




More information about the TYPO3-project-rte mailing list