无法在RTE中选择文字样式 [英] Cannot choose text style in RTE
问题描述
在根页面的Page TSConfig
中,我具有以下代码:
In the Page TSConfig
on the root page I have the following code:
/////////////////////////////////////////////////////////////
// RTE
/////////////////////////////////////////////////////////////
RTE.classes{
highlight{
name = highlight
value = color:#636466; font-size:15px;
}
brown{
name = braun
value = color:#9A3811;
}
}
RTE.default{
ignoreMainStyleOverride = 1
useCSS = 1
contentCSS = fileadmin/templates/css/rte.css
classesCharacter := addToList(highlight, brown)
classesParagraph := addToList(highlight, brown)
proc.allowedClasses := addToList(highlight, brown)
showTagFreeClasses = 1
}
在我的rte.css
中,我有这个:
/* content of rte.css */
.highlighthighlight {
font-size: 15px;
color: #636466;
}
.brown {
color: #9A3811;
}
style.css
中的前端具有相同的样式.如果我在编辑器中,则无法选择文本样式.它始终是禁用的.我想在段落中标记一些单词.我尝试使用其他浏览器(IE,FF,Opera ...),但所有浏览器均禁用了文本样式.我该怎么办?
The same style is in style.css
for the frontend. If I'm in the editor I cannot choose a text style. It is always disabled. I want to mark some words in a paragraph. I tried to use different browsers (IE, FF, Opera ...) but in all of them text style is disabled. What can I do?
我有Typo3 4.7.5
I have Typo3 4.7.5
编辑
问题是由于不推荐使用的属性(请参见此处)).我当前的代码如下
The problem was due to deprecated properties (see here)). My current code looks like
/////////////////////////////////////////////////////////////
// RTE
/////////////////////////////////////////////////////////////
RTE.default{
ignoreMainStyleOverride = 1
useCSS = 1
contentCSS = fileadmin/templates/css/rte.css
proc.allowedClasses := addToList(highlight, brown)
buttons {
blockstyle.tags.div.allowedClasses := addToList(highlight, brown)
textstyle.tags.span.allowedClasses := addToList(highlight, brown)
}
showTagFreeClasses = 1
}
RTE.classes{
highlight{
name = highlight
value = color:#636466; font-size:15px;
}
brown{
name = braun
value = color:#9A3811;
}
}
现在我可以选择一种文字样式,但是只能选择其中一种.同样,一个块样式的名称是错误的...
Now I can choose a text style, but only one of them. Also the name of one block style is wrong ...
推荐答案
我的rte.css错误.这似乎可行.
I had an error in my rte.css. This seems to work.
rte.css
div.highlight, span.highlight, p.highlight, .brown {
font-size: 15px;
color: #636466;
}
div.brown, span.brown, p.brown, .brown {
color: #9A3811;
}
页面TSConfig
/////////////////////////////////////////////////////////////
// RTE
/////////////////////////////////////////////////////////////
RTE.classes{
highlight{
name = highlight
value = color:#636466; font-size:15px;
}
brown{
name = braun
value = color:#9A3811;
}
}
RTE.default{
ignoreMainStyleOverride = 1
useCSS = 1
showTagFreeClasses = 1
contentCSS = fileadmin/templates/css/rte.css
buttons {
blockstyle.tags.div.allowedClasses := addToList(highlight, brown)
blockstyle.tags.p.allowedClasses := addToList(highlight, brown)
textstyle.tags.span.allowedClasses := addToList(highlight, brown)
}
proc.allowedClasses := addToList(highlight, brown)
}
这篇关于无法在RTE中选择文字样式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!