Ich habe ein riesen Problem mit dem htmlarea RTE von Typo3. Bei meiner Eingabe mit Beispieltexten wird mir im BE der Text in den gewünschten Absätzen (p-Tag) angezeigt.
<p>Sport tut gut!</p>
<p>Ach ja!</p>
Dazu hatte ich noch einen Überschrift eingegeben.
Doch was macht der RTE nun im Frontend?
Das hier:
<header class="csc-header csc-header-n1"><h1><h1>Verein</h1></h1></header>Sport tut gut!
<br/>
Ach ja!<br/>
Ich verstehe das nicht. Diese header class soll nicht da sein und die doppelten h1 Tags auch nicht. Die p-Tags werden komplett ignoriert.
Hier mal die Konfiguration aus meiner pageTS der ROOT Seite:
# ***************************************************************************************
# TYPO3 htmlArea RTE configuration
#
# Author: Felix Nagel for Paints Multimedia GmbH, http://www.paints.de
# Info & DL: http://www.felixnagel.com/blog/kategorie/typo3/
# ***************************************************************************************
# Define labels and styles to be applied to class selectors in the interface of the RTE
RTE.classes >
# this class needs to be added to you CSS file (contentCSS)
RTE.classes.special-text {
name = Abgesetzter Text
}
# Anchor classes configuration for use by the anchor accesibility feature (htmlArea RTE only)
RTE.classesAnchor >
# Default RTE configuration
RTE.default {
# add CSS file for rte
contentCSS =
# disable right click
disableRightClick = 1
# acronym sys folder (id, not needed for admins as webmount is used)
# buttons.acronym.pages = 306
# buttons.lockBEUserToDBmounts = 1
# image in RTE relevant
# please note you need to enable images in the EM and add width and height to RTE.default.proc.entryHTMLparser_db.tags.img.allowedAttribs
# media_ prefix when using DAM, see http://bugs.typo3.org/bug_view_advanced_page.php?bug_id=13902
buttons.image.options.removeItems = dragdrop, media_dragdrop, magic, media_magic
buttons.image.options.plain.maxWidth = 960
buttons.image.options.plain.maxHeight = 1000
buttons.image.properties.removeItems = align, border, float, paddingTop, paddingRight, paddingBottom, paddingLeft, clickenlarge
# clean out crap
removeComments = 1
enableWordClean = 1
# removed strike and u tag from default config
removeTags = center, font, o:p, sdfield
# modified showButtons array (should be sufficient in most use cases)
# row 1: text styles and tools
# row 2: standard buttons
# row 3: table operations
showButtons (
blockstyle, formatblock, bar, copy, cut, paste, pastebehaviour, pastetoggle, findreplace, bar, undo, redo, bar, linebreak,
link, image, bar, bold, italic, underline, strikethrough, bar, subscript, superscript, bar, orderedlist, unorderedlist, acronym, insertcharacter, line, bar, removeformat, chMode
)
# need to use one line! Just copy showButtons into one line!
toolbarOrder = blockstyle, formatblock, copy, cut, paste, pastebehaviour, pastetoggle, findreplace, bar, undo, redo, bar, linebreak, link, image, bar, bold, italic, underline, strikethrough, bar, subscript, superscript, bar, orderedlist, unorderedlist, acronym, insertcharacter, line, bar, removeformat, chMode
# added div element to default config
hidePStyleItems = pre,address,div
# Use stylesheet file rather than the above mainStyleOverride and inlineStyle properties to style the contents (htmlArea RTE only).
# ignoreMainStyleOverride = 1
# List all class selectors that are allowed on the way to the database
proc.allowedClasses (
more,
pdf,
external-link,
lightbox,
special-text
)
# Configuration of the anchor accessibility feature (htmlArea RTE only)
# These classes should also be in the list of allowedClasses.
classesAnchor = more, more-button, external-link, modalbox, modalbox-big, company, exploration, oilgas
classesAnchor.default {
page =
url =
file =
mail =
}
}
# needed, otherwise enableWordClean wont work, regression, see http://forge.typo3.org/issues/19697
RTE.default.showButtons := addToList(cleanword)
RTE.default.toolbarOrder := addToList(cleanword)
# Use same processing as on entry to database to clean content pasted into the editor
RTE.default.enableWordClean.HTMLparser < RTE.default.proc.entryHTMLparser_db
# remove all classes so we have a clean start after pasting (allowed classed wont work on enableWordClean)
RTE.default.enableWordClean.HTMLparser.tags.p.fixAttrib.class.unset = 1
# make DAM usable in tt_news entries
RTE.config.tt_news.bodytext.proc.overruleMode = ts_css,txdam_media
Hier noch weiteres Typoscript von diversen Seiten für die Aufräumung des Quelltextes etc.:
##
## SETUP STOP
##
##
## GRUNDCONFIGURATION STOP
##
config {
disablePrefixComment = 1 ###Kommentare vor CEs abschalten
inlineStyle2TempFile = 1 ###TYPO3-Styles in Datei auslagern
removeDefaultJS = external ###Default-JS in Datei auslagern
pageTitleFirst = 1 ###Erst Seitentitel: dann Name der Webseite
meaningfulTempFilePrefix = 100 ###100 Zeichen des Quelldateinamens verwenden
}
tt_content.stdWrap.innerWrap.cObject.default.15 > ###Klasse csc-default aus id-Div entfernen - in 4.7 15 durch 20 ersetzen
#tt_content.stdWrap.innerWrap > ###id-Divs komplett entfernen
lib.stdheader.stdWrap.dataWrap = ###Div um Überschriften entfernen
lib.stdheader.3 > ###Klassen der Überschriften entfernen
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines.addAttributes.P.class > ###Klasse bodytext aus p entfernen
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines.nonWrappedTag >
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines.wrapNonWrappedLines = | <br/>
##Überschriften von Klassen Attribut befreien
lib.stdheader {
10.1.fontTag = <h1>|</h1>
10.2.fontTag = <h3>|</h3>
10.3.fontTag = <h3>|</h3>
10.4.fontTag = <h4>|</h4>
10.5.fontTag = <h5>|</h5>
stdWrap.dataWrap = |
}
##Typo3 Kommentare entfernen
page.config.disablePrefixComment = true
lib.stdheader.10.stdWrap.wrap = |
tt_content.stdWrap.dataWrap >
tt_content.header.20.dataWrap >
tt_content.mailform.20.stdWrap.wrap >
tt_content.stdWrap.innerWrap.cObject >
tt_content.stdWrap.innerWrap.cObject.default >
styles.content.imgtext.caption.1.wrap = |
##Klasse Bodytext in p Tag entfernen
lib.parseFunc_RTE.nonTypoTagStdWrap.encapsLines.addAttributes.P.class >
nonTypoTagStdWrap.encapsLines {
encapsTagList = div,p,pre,h1,h2,h3,h4,h5,h6
remapTag.DIV = P
nonWrappedTag = P
innerStdWrap_all.ifEmpty =
addAttributes.P.class = bodytext
addAttributes.P.class.setOnly=blank
}
Woran liegen diese Probleme?