[TASK] Organize TSconfig structure
[Packages/TYPO3.CMS.git] / typo3 / sysext / rtehtmlarea / Configuration / PageTSconfig / Proc / pageTSConfig.txt
1 # ***************************************************************************************
2 # Default proc options in Page TSconfig for htmlArea RTE
3 #
4 # Sets the proc options for all default configurations.
5 #
6 # Assumptions:  - CSS Styled Content is installed.
7 #               - XHTML output is expected.
8 #
9 # ***************************************************************************************
10
11         ## Default RTE processing rules
12 RTE.default.proc {
13
14                 ## TRANSFORMATION METHOD
15                 ## We assume that CSS Styled Content is used.
16         overruleMode = ts_css
17
18                 ## DO NOT CONVERT BR TAGS INTO LINEBREAKS
19                 ## br tags in the content are assumed to be intentional.
20         dontConvBRtoParagraph = 1
21
22                 ## PRESERVE DIV SECTIONS - DO NOT REMAP TO P
23         preserveDIVSections = 1
24
25                 ## TAGS ALLOWED OUTSIDE P & DIV
26         allowTagsOutside = address, article, aside, blockquote, footer, header, hr, nav, section
27
28                 ## TAGS ALLOWED
29                 ## 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
30                 ## But, for the sake of clarity, we use a complete list in alphabetic order.
31                 ## center, font, link, meta, o:p, strike, sdfield, style, title and u will be removed on entry (see below).
32                 ## b and i will be remapped on exit (see below).
33                 ## Note that the link accessibility feature of htmlArea RTE does insert img tags.
34         allowTags = a, abbr, acronym, address, article, aside, b, bdo, big, blockquote, br, caption, center, cite, code, col, colgroup, dd, del, dfn, dl, div, dt, em, font, footer
35         allowTags := addToList(header, h1, h2, h3, h4, h5, h6, hr, i, img, ins, kbd, label, li, link, meta, nav, ol, p, pre, q, samp, sdfield, section, small)
36         allowTags := addToList(span, strike, strong, style, sub, sup, table, thead, tbody, tfoot, td, th, tr, title, tt, u, ul, var)
37
38                 ## TAGS DENIED
39                 ## Make sure we can set rules on any tag listed in allowTags.
40         denyTags >
41
42                 ## ALLOWED P & DIV ATTRIBUTES
43                 ## Attributes class and align are always preserved
44                 ## Align attribute will be unset on entry (see below)
45                 ## This is a list of additional attributes to keep
46         keepPDIVattribs = id, title, dir, lang, xml:lang, itemscope, itemtype, itemprop
47
48                 ## REMAP BOLD AND ITALIC TO STRONG AND EMPHASIS AND VICE VERSA
49         transformBoldAndItalicTags = 1
50
51                 ## ALLOW TO WRITE ABOUT HTML
52         dontUndoHSC_db = 1
53         dontHSC_rte = 1
54
55                 ## CONTENT TO DATABASE
56         entryHTMLparser_db = 1
57         entryHTMLparser_db {
58
59                         ## TAGS ALLOWED
60                         ## Always use the same list of allowed tags.
61                 allowTags < RTE.default.proc.allowTags
62
63                         ## TAGS DENIED
64                         ## Make sure we can set rules on any tag listed in allowTags.
65                 denyTags >
66
67                         ## AVOID CONTENT BEING HSC'ed TWICE
68                 htmlSpecialChars = 0
69
70                 tags {
71
72                                 ## REMOVE IMG TAGS
73                         img.allowedAttribs = 0
74                         img.rmTagIfNoAttrib = 1
75
76                                 ## CLEAN ATTRIBUTES ON THE FOLLOWING TAGS
77                         span.fixAttrib.style.unset = 1
78                         span.allowedAttribs = id, title, dir, lang, xml:lang, class, itemscope, itemtype, itemprop
79                         span.rmTagIfNoAttrib = 1
80                         p {
81                                 allowedAttribs = id, title, dir, lang, xml:lang, class, itemscope, itemtype, itemprop
82                                 fixAttrib.align.unset = 1
83                         }
84                         div < .p
85                         hr.allowedAttribs = class
86                         b.allowedAttribs < .span.allowedAttribs
87                         bdo.allowedAttribs < .span.allowedAttribs
88                         big.allowedAttribs < .span.allowedAttribs
89                         blockquote.allowedAttribs < .span.allowedAttribs
90                         cite.allowedAttribs < .span.allowedAttribs
91                         code.allowedAttribs < .span.allowedAttribs
92                         del.allowedAttribs < .span.allowedAttribs
93                         dfn.allowedAttribs < .span.allowedAttribs
94                         em.allowedAttribs < .span.allowedAttribs
95                         i.allowedAttribs < .span.allowedAttribs
96                         ins.allowedAttribs < .span.allowedAttribs
97                         kbd.allowedAttribs < .span.allowedAttribs
98                         label.allowedAttribs < .span.allowedAttribs
99                         q.allowedAttribs < .span.allowedAttribs
100                         samp.allowedAttribs < .span.allowedAttribs
101                         small.allowedAttribs < .span.allowedAttribs
102                         strike.allowedAttribs < .span.allowedAttribs
103                         strong.allowedAttribs < .span.allowedAttribs
104                         sub.allowedAttribs < .span.allowedAttribs
105                         sup.allowedAttribs < .span.allowedAttribs
106                         tt.allowedAttribs < .span.allowedAttribs
107                         u.allowedAttribs < .span.allowedAttribs
108                         var.allowedAttribs < .span.allowedAttribs
109                 }
110
111                         ## REMOVE OPEN OFFICE META DATA TAGS, WORD 2003 TAGS, LINK, META, STYLE AND TITLE TAGS, AND DEPRECATED HTML TAGS
112                         ## We use this rule instead of the denyTags rule so that we can protect custom tags without protecting these unwanted tags.
113                 removeTags = center, font, link, meta, o:p, sdfield, strike, style, title, u
114
115                         ## PROTECT CUSTOM TAGS
116                 keepNonMatchedTags = protect
117         }
118
119         HTMLparser_db {
120                         ## STRIP ALL ATTRIBUTES FROM THESE TAGS
121                         ## 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.
122                         ## However, we want to keep xml:lang attribute on most tags and tags from the default list where cleaned on entry.
123                 noAttrib = br
124
125                         ## XHTML COMPLIANCE
126                         ## Note that applying xhtml_cleaning on exit would break non-standard attributes of typolink tags
127                 xhtml_cleaning = 1
128         }
129
130         exitHTMLparser_db = 1
131         exitHTMLparser_db {
132                         ## KEEP ALL TAGS
133                         ## Unwanted tags were removed on entry.
134                         ## Without this rule, the parser will remove all tags! Presumably, this rule will be more efficient than repeating the allowTags rule
135                 keepNonMatchedTags = 1
136
137                         ## AVOID CONTENT BEING HSC'ed TWICE
138                 htmlSpecialChars = 0
139         }
140 }
141
142         ## Use same RTE processing rules in FE
143 RTE.default.FE.proc < RTE.default.proc
144
145         ## RTE processing rules for bodytext column of tt_content table
146         ## Erase settings from other extensions
147 RTE.config.tt_content.bodytext >
148
149         ## Make sure we use ts_css transformation
150 RTE.config.tt_content.bodytext.proc.overruleMode = ts_css
151 RTE.config.tt_content.bodytext.types.text.proc.overruleMode = ts_css
152 RTE.config.tt_content.bodytext.types.textpic.proc.overruleMode = ts_css