css没有在Liferay主题中应用到速度模板 [英] css not getting applied for velocity template in Liferay Theme
问题描述
我正在使用LIferay主题来创建网站的主题.在portal_normal.vm文件中,我包含了在custom.css中定义的所有html代码和css
I am using LIferay Theme to create a theme for a website. IN the portal_normal.vm file, I have included all the html code and css I have defined in custom.css
问题是来自custom.css的css没有被应用到portal_normal.vm页面
THe problem is that css from custom.css is not getting applied to portal_normal.vm page
我应该在速度文件中包含一些文件来告知应该包含custom.css吗?
SHould I include some file in velocity file which tells that custom.css should be included?
还可以在速度中包含所有CSS代码吗?
Also is it ok to include all css code in velocity?
问候
custom.css和portal_normal.vm位于_diffs文件夹中
custom.css and portal_normal.vm are inside _diffs folder
推荐答案
将custom.css放在〜/theme/docroot/_diffs/css/custom.css
put the custom.css under ~/theme/docroot/_diffs/css/custom.css
请参见〜/theme/docroot/css/main.css
中的main.css,其中应包含
see the main.css in ~/theme/docroot/css/main.css
it should include
...
@import url(custom.css);
...
这篇关于css没有在Liferay主题中应用到速度模板的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!