[TYPO3-german] RTE -- SPAN Tags werden beim speichern entfernt wenn mehr als eine Klasse zugewiesen wird!
Michael Karrer
m.karrer at bt-center.at
Thu Mar 26 17:48:42 CET 2009
useCSS ist deaktiviert und vom Browser ist es nicht! abhängig
ich denke es müsste ein setting vom proc teil sein aber wie gesagt hab ewig gesucht und nix gefunden! Klappt es denn bei dir dass du mehrere klassen zuweist?!? dass wär immerhin ein wichtiger hinweis!
Hier meine config:
------------------
## By Mike: i unset everything first just to make sure!
RTE.default >
RTE.classes >
RTE.classesAnchor >
# ***************************************************************************************
# Default proc options in Page TSconfig for htmlArea RTE and Classic RTE
#
# Sets the proc options for all default configurations.
#
# Assumptions: - CSS Styled Content is installed.
# - XHTML output is expected.
#
# For documentation of RTE tranformations, see: http://typo3.org/documentation/document-library/core-documentation/doc_core_api/4.1.0/view/5/2/
# For documentation of Page TSConfig configuration of RTE processing, see: http://typo3.org/documentation/document-library/doc_core_api/Page_TSconfig/
# For documentation of the HTMLparser, see: http://typo3.org/documentation/document-library/doc_core_tsref/HTMLparser/
# For documentation of RTE settings in TCA, see: http://typo3.org/documentation/document-library/core-documentation/doc_core_api/4.1.0/view/4/3/#id3665895
#
# @author Stanislas Rolland <stanislas.rolland(arobas)fructifor.ca>
#
# TYPO3 SVN ID: $Id: pageTSConfig.txt 3971 2008-08-12 21:13:52Z stan $
# ***************************************************************************************
## Default RTE processing rules
RTE.default.proc {
## TRANSFORMATION METHOD
## We assume that CSS Styled Content is used.
overruleMode = ts_css
## DO NOT CONVERT BR TAGS INTO LINEBREAKS
## br tags in the content are assumed to be intentional.
dontConvBRtoParagraph = 1
## PRESERVE DIV SECTIONS - DO NOT REMAP TO P
preserveDIVSections = 1
## TAGS ALLOWED OUTSIDE P & DIV
allowTagsOutside = hr, address
## TAGS ALLOWED
## Added to the default internal list: b,i,u,a,img,br,div,center,pre,font,hr,sub,sup,p,strong,em,li,ul,ol,blockquote,strike,span
## But, for the sake of clarity, we use a complete list in alphabetic order.
## center, font, link, meta, o:p, strike, sdfield, style, title and u will be removed on entry (see below).
## b and i will be remapped on exit (see below).
## Note that the link accessibility feature of htmlArea RTE does insert img tags.
## By Mike: unsetting it first will make sure to only use those tags!
allowTags >
allowTags (
a, br, div, h1, h2, h3, h4, h5, h6, img, li, link, meta, ol, p,
span, table, thead, tbody, tfoot, td, th, tr, hr, ul, title
## By Mike: I normaly i dont want those tags:
#abbr, acronym, address, b, bdo, big, blockquote, caption, center, cite, code, col, colgroup, del, dfn, i,
#ins, kbd, label, em, font, tt, u, strike, strong, style, sub, sup, var, pre, q, samp, sdfield, small
)
## TAGS DENIED
## Make sure we can set rules on any tag listed in allowTags.
denyTags >
## ALLOWED P & DIV ATTRIBUTES
## Attributes class and align are always preserved
## Align attribute will be unset on entry (see below)
## This is a list of additional attributes to keep
keepPDIVattribs = id, title, dir, lang, xml:lang
## REMAP BOLD AND ITALIC TO STRONG AND EMPHASIS AND VICE VERSA
transformBoldAndItalicTags = 1
## ALLOW TO WRITE ABOUT HTML
dontUndoHSC_db = 1
dontHSC_rte = 1
## CONTENT TO DATABASE
entryHTMLparser_db = 1
entryHTMLparser_db {
## TAGS ALLOWED
## Always use the same list of allowed tags.
allowTags < RTE.default.proc.allowTags
## TAGS DENIED
## Make sure we can set rules on any tag listed in allowTags.
denyTags >
## AVOID CONTENT BEING HSC'ed TWICE
htmlSpecialChars = 0
tags {
## REMOVE IMG TAGS
## By Mike: will be enabled later on!
img.allowedAttribs = 0
img.rmTagIfNoAttrib = 1
## CLEAN ATTRIBUTES ON THE FOLLOWING TAGS
span.fixAttrib.style.unset = 1
p {
allowedAttribs = id, title, dir, lang, xml:lang, class
fixAttrib.align.unset = 1
}
div < .p
span.allowedAttribs = class
hr.allowedAttribs = class
b.allowedAttribs = id, title, dir, lang, xml:lang, class
bdo.allowedAttribs = id, title, dir, lang, xml:lang, class
big.allowedAttribs = id, title, dir, lang, xml:lang, class
blockquote.allowedAttribs = id, title, dir, lang, xml:lang, class
cite.allowedAttribs = id, title, dir, lang, xml:lang, class
code.allowedAttribs = id, title, dir, lang, xml:lang, class
del.allowedAttribs = id, title, dir, lang, xml:lang, class
dfn.allowedAttribs = id, title, dir, lang, xml:lang, class
em.allowedAttribs = id, title, dir, lang, xml:lang, class
i.allowedAttribs = id, title, dir, lang, xml:lang, class
ins.allowedAttribs = id, title, dir, lang, xml:lang, class
kbd.allowedAttribs = id, title, dir, lang, xml:lang, class
label.allowedAttribs = id, title, dir, lang, xml:lang, class
q.allowedAttribs = id, title, dir, lang, xml:lang, class
samp.allowedAttribs = id, title, dir, lang, xml:lang, class
small.allowedAttribs = id, title, dir, lang, xml:lang, class
strike.allowedAttribs = id, title, dir, lang, xml:lang, class
strong.allowedAttribs = id, title, dir, lang, xml:lang, class
sub.allowedAttribs = id, title, dir, lang, xml:lang, class
sup.allowedAttribs = id, title, dir, lang, xml:lang, class
tt.allowedAttribs = id, title, dir, lang, xml:lang, class
u.allowedAttribs = id, title, dir, lang, xml:lang, class
var.allowedAttribs = id, title, dir, lang, xml:lang, class
}
## REMOVE OPEN OFFICE META DATA TAGS, WORD 2003 TAGS, LINK, META, STYLE AND TITLE TAGS, AND DEPRECATED HTML TAGS
## We use this rule instead of the denyTags rule so that we can protect custom tags without protecting these unwanted tags.
removeTags = center, font, link, o:p, sdfield, meta, style, title, strike, u
## PROTECT CUSTOM TAGS
keepNonMatchedTags = protect
}
HTMLparser_db {
## STRIP ALL ATTRIBUTES FROM THESE TAGS
## If this list of tags is not set, it will default to: b,i,u,br,center,hr,sub,sup,strong,em,li,ul,ol,blockquote,strike.
## However, we want to keep xml:lang attribute on most tags and tags from the default list where cleaned on entry.
noAttrib = br
## XHTML COMPLIANCE
## Note that applying xhtml_cleaning on exit would break non-standard attributes of typolink tags
xhtml_cleaning = 1
}
exitHTMLparser_db = 1
exitHTMLparser_db {
## KEEP ALL TAGS
## Unwanted tags were removed on entry.
## Without this rule, the parser will remove all tags! Presumably, this rule will be more efficient than repeating the allowTags rule
keepNonMatchedTags = 1
## AVOID CONTENT BEING HSC'ed TWICE
htmlSpecialChars = 0
}
}
## Use same RTE processing rules in FE
RTE.default.FE.proc < RTE.default.proc
## RTE processing rules for bodytext column of tt_content table
## Erase settings from other extensions
RTE.config.tt_content.bodytext >
## Make sure we use ts_css transformation
RTE.config.tt_content.bodytext.proc.overruleMode = ts_css
RTE.config.tt_content.bodytext.types.text.proc.overruleMode = ts_css
RTE.config.tt_content.bodytext.types.textpic.proc.overruleMode = ts_css
# ***************************************************************************************
# "Demo" Page TSconfig for htmlArea RTE
#
# Sets default Page TSConfig with maximal features for users who want to explore the features of the RTE.
#
# TYPO3 SVN ID: $Id: pageTSConfig.txt 4140 2008-09-17 02:57:32Z stan $
# ***************************************************************************************
## Define labels and styles to be applied to class selectors in the interface of the RTE
## Partial re-use of color scheme and frame scheme from CSS Styled Content extension
RTE.classes {
align-left {
name = LLL:EXT:rtehtmlarea/htmlarea/locallang_tooltips.xml:justifyleft
value = text-align: left;
}
align-center {
name = LLL:EXT:rtehtmlarea/htmlarea/locallang_tooltips.xml:justifycenter
value = text-align: center;
}
align-right {
name = LLL:EXT:rtehtmlarea/htmlarea/locallang_tooltips.xml:justifyright
value = text-align: right;
}
}
## Anchor classes configuration for use by the anchor accesibility feature (htmlArea RTE only)
RTE.classesAnchor {
externalLink {
class = external-link
type = url
image = EXT:rtehtmlarea/res/accessibilityicons/img/external_link.gif
altText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:external_link_altText
titleText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:external_link_titleText
}
externalLinkInNewWindow {
class = external-link-new-window
type = url
image = EXT:rtehtmlarea/res/accessibilityicons/img/external_link_new_window.gif
altText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:external_link_new_window_altText
titleText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:external_link_new_window_titleText
}
internalLink {
class = internal-link
type = page
image = EXT:rtehtmlarea/res/accessibilityicons/img/internal_link.gif
altText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:internal_link_altText
titleText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:internal_link_titleText
}
internalLinkInNewWindow {
class = internal-link-new-window
type = page
image = EXT:rtehtmlarea/res/accessibilityicons/img/internal_link_new_window.gif
altText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:internal_link_new_window_altText
titleText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:internal_link_new_window_titleText
}
download {
class = download
type = file
image = EXT:rtehtmlarea/res/accessibilityicons/img/download.gif
altText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:download_altText
titleText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:download_titleText
}
mail {
class = mail
type = mail
image = EXT:rtehtmlarea/res/accessibilityicons/img/mail.gif
altText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:mail_altText
titleText = LLL:EXT:rtehtmlarea/res/accessibilityicons/locallang.xml:mail_titleText
}
}
## Default RTE configuration
RTE.default {
## Markup options (htmlArea RTE only)
enableWordClean = 1
removeTrailingBR = 1
removeComments = 1
removeTags = center, o:p, sdfield
removeTagsAndContents = link, meta, script, style, title
## Allow img tags
proc.entryHTMLparser_db.tags.img >
## Toolbar options
## By Mike: Full List:
## blockstylelabel, blockstyle, textstylelabel, textstyle, fontstyle, fontsize, formatblock, blockquote, insertparagraphbefore, insertparagraphafter,
## lefttoright, righttoleft, left, center, right, justifyfull, orderedlist, unorderedlist, outdent, indent, formattext, bidioverride, big, bold, citation, code, definition, deletedtext, emphasis, insertedtext, italic, keyboard, monospaced, quotation, sample, small, span, strikethrough, strong, subscript, superscript, underline,
## variable, textcolor, bgcolor, textindicator, emoticon, insertcharacter, line, link, unlink, image, table, user, acronym, findreplace, spellcheck, chMode, inserttag, removeformat, copy, cut, paste, undo, redo, showhelp, about,
## toggleborders, tableproperties, tablerestyle, rowproperties, rowinsertabove, rowinsertunder, rowdelete, rowsplit, columnproperties, columninsertbefore, columninsertafter, columndelete, columnsplit, cellproperties, cellinsertbefore, cellinsertafter, celldelete, cellsplit, cellmerge
showButtons = *
hideButtons = textindicator, formattext, bold, italic, big, small, insertedtext, deletedtext, citation, code, definition, keyboard, monospaced, quotation, sample, variable, bidioverride, span, fontstyle, fontsize, blockquote, left, lefttoright, righttoleft, textcolor, bgcolor, emoticon, user, acronym, inserttag, showhelp, about, spellcheck
## By Mike: Mikes Toolbar order
toolbarOrder >
toolbarOrder (
formatblock, insertparagraphbefore, insertparagraphafter,
bar, blockstylelabel, blockstyle, space, textstylelabel, textstyle,
linebreak,
textindicator,
bar, textcolor, bgcolor,
bar, center, right, justifyfull,
bar, outdent, indent, bar, orderedlist, unorderedlist,
bar, formattext, blockquote, bold, strong, italic, emphasis, big, small, insertedtext, deletedtext, citation, code, definition, keyboard, monospaced, quotation, sample, variable, bidioverride, strikethrough, subscript, superscript, underline, span,
bar, fontstyle, space, fontsize,
bar, removeformat, findreplace, spellcheck, chMode,
bar, lefttoright, righttoleft,
linebreak,
copy, cut, paste,
bar, undo, redo,
bar, emoticon, insertcharacter, line, image,
bar, link, unlink,
bar, table, toggleborders,
bar, user, acronym, inserttag,
bar, showhelp, about,
linebreak,
tableproperties, tablerestyle,
bar, rowproperties, rowinsertabove, rowinsertunder, rowdelete, rowsplit,
bar, columnproperties, columninsertbefore, columninsertafter, columndelete, columnsplit,
bar, cellproperties, cellinsertbefore, cellinsertafter, celldelete, cellsplit, cellmerge
)
## More toolbar options (htmlArea RTE only)
keepButtonGroupTogether = 1
## Enable status bar (htmlArea RTE only)
showStatusBar = 1
## Add default example styles
## Left, center, right and justify alignment of text in block elements
inlineStyle.text-alignment (
p.align-left, h1.align-left, h2.align-left, h3.align-left, h4.align-left, h5.align-left, h6.align-left, div.align-left, address.align-left { text-align: left; }
p.align-center, h1.align-center, h2.align-center, h3.align-center, h4.align-center, h5.align-center, h6.align-center, div.align-center, address.align-center { text-align: center; }
p.align-right, h1.align-right, h2.align-right, h3.align-right, h4.align-right, h5.align-right, h6.align-right, div.align-right, address.align-right { text-align: right; }
p.align-justify, h1.align-justify, h2.align-justify, h3.align-justify, h4.align-justify, h5.align-justify, h6.align-justify, div.align-justify, address.align-justify { text-align: justify; }
)
## Default selectors for the default configuration of the link accessibity feature.
inlineStyle.accessibility (
a.external-link {}
a.external-link-new-window {}
a.internal-link {}
a.internal-link-new-window {}
a.download {}
a.mail {}
)
## Default selector for indentation.
inlineStyle.indentation (
div.indent { margin-left: 2em; }
)
## Use stylesheet file rather than the above mainStyleOverride and inlineStyle properties to style the contents (htmlArea RTE only)
## When RTE.default.contentCSS is not specified, file EXT:rtehtmlarea/res/contentcsss/default.css is used.
ignoreMainStyleOverride = 1
contentCSS = fileadmin/templates/agatos_v01/css/screen/typo3_rte.css
## For this demo, do not remove font, strike and u tags
## By mike: Do remove it since meking new classes makes more sence
#proc.entryHTMLparser_db.removeTags := removeFromList(font,strike,u)
## List all class selectors that are allowed on the way to the database
## By Mike: List all classes needed here! I Disabled the classes i dont want to have!
proc.allowedClasses (
external-link, external-link-new-window, internal-link, internal-link-new-window, download, mail,
align-left, align-center, align-right, align-justify,
indent, important,
teaser, smallest_text, note, info, highlight, dimmed, underline, strikethrough, aga_red
)
## If these Attributes are present then you have to specify this classes doubled so do not uncomment them but rather set the classes in your contentCSS
#buttons.blockstyle.tags.p.allowedClasses >
#buttons.blockstyle.tags.div.allowedClasses >
#buttons.blockstyle.tags.table.allowedClasses >
#buttons.blockstyle.tags.td.allowedClasses >
#buttons.blockstyle.tags.a.allowedClasses = external-link, external-link-new-window, internal-link, internal-link-new-window, download, mail
#buttons.blockstyle.showTagFreeClasses = 0
#buttons.textstyle.tags.span.allowedClasses >
#buttons.textstyle.showTagFreeClasses = 0
#classesImage =
classesAnchor = external-link, external-link-new-window, internal-link, internal-link-new-window, download, mail
classesAnchor.default {
page = internal-link
url = external-link-new-window
file = download
mail = mail
}
## Configuration specific to the table button or TableOperations feature (htmlArea RTE only)
## Use the context menu instead of the toolbar for table operations, but keep toggleborders button in toolbar
## Show borders on table creation
hideTableOperationsInToolbar = 1
buttons.toggleborders.keepInToolbar = 1
buttons.toggleborders.setOnTableCreation = 1
buttons.table.disableEnterParagraphs = 1
## Configuration specific to the inserttag button or QuickTag feature (htmlArea RTE only)
## Do not allow insertion of the following tags
buttons.inserttag.denyTags = font, underline, strike, abbr, acronym, address, big, blockquote, cite, code, div, em, fieldset, font, i, legend, pre, q, small, sub, sup, tt
## By Mike: This are the options for the blockformat dropdown list (so for the containers like p div and so on)
buttons.formatblock.removeItems = div, address, pre, blockquote
## By Mike:
## Remove this Styles from the formattext dropdown list
## use the names of the buttons! not of the elements
#buttons.formattext.removeItems =
## Configuration specific to the bold and italic buttons (htmlArea RTE only)
## Add hotkeys associated with bold, italic, strikethrough and underline buttons
#buttons.bold.hotKey = b
#buttons.italic.hotKey = i
#buttons.strikethrough.hotKey = s
#buttons.underline.hotkey = u
## Configuration specific to the spellcheck button or SpellCheck feature (htmlArea RTE only)
## Enable the use of personal dictionaries
enablePersonalDicts = 1
}
## Use same processing as on entry to database to clean content pasted into the editor
RTE.default.enableWordClean.HTMLparser < RTE.default.proc.entryHTMLparser_db
## front end RTE configuration (htmlArea RTE only)
RTE.default.FE < RTE.default
RTE.default.FE.FE >
RTE.default.FE.userElements >
RTE.default.FE.userLinks >
## tt_content TCEFORM configuration
## Let use all the space available for more comfort.
TCEFORM.tt_content.bodytext.RTEfullScreenWidth= 100%
------------------
mfg
mike
----- Ursprüngliche Mail -----
Von: "Bernt Orlich" <borlich at i-dial.de>
An: "German TYPO3 Userlist" <typo3-german at lists.netfielders.de>
Gesendet: Donnerstag, 26. März 2009 14:40:04 GMT +01:00 Amsterdam/Berlin/Bern/Rom/Stockholm/Wien
Betreff: Re: [TYPO3-german] RTE -- SPAN Tags werden beim speichern entfernt wenn mehr als eine Klasse zugewiesen wird!
Hi
On Thu, Mar 26, 2009 at 02:10:25PM +0100, Michael Karrer wrote:
> Ich bastel jetzt schon einige Tage an meiner "perfekten" RTE Konfiguration für Typo3 4.2.6. Leider bleibt ein Problem bestehen:
>
>
> SPAN Tags werden beim speichern entfernt wenn mehr als eine Klassen zugewiesen wird!
Verwendest du FF? Klappt es im IE?
Wie schauen die
# RTE-Default-Settings
in der Page TS Conig aus?
steht da
useCSS = 1
kommentier das mal aus.
Gruss
Bernt
_______________________________________________
TYPO3-german mailing list
TYPO3-german at lists.netfielders.de
http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-german
More information about the TYPO3-german
mailing list