需要在Liferay中更改模板样式 [英] Need to change template styles in Liferay

查看:111
本文介绍了需要在Liferay中更改模板样式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用CSS改变liferay的外观.我对liferay非常陌生.谁能给我任何想法进行更改.预先感谢

I want to change look and feel of liferay using css. i am very new to liferay. Can any give me any idea to do the changes. Thanks in advance

推荐答案

分步操作似乎很复杂,但是还不错.....

The step-by-step seems complicated, but it's not that bad .....

1a)下载并解压缩要使用的liferay版本的sdk插件.所有下载均在sf页面上 http://lportal.sourceforge.net/

1a) download and unpack the plugins sdk for the version of liferay you want to use. All the downloads are on the sf page http://lportal.sourceforge.net/

1b)确保您拥有最新版本的ant和与您的liferay版本(1.5.x或1.6.x)匹配的JDK版本

1b) make sure you have the latest version of ant and the JDK version that matches your liferay version (1.5.x or 1.6.x)

2)套件中有一些主文件夹.转到主题"文件夹,然后以这种格式在其中运行创建脚本(在Linux或Mac上,您需要使.sh文件可执行)

2) there are a few main folders in the kit. Change into the "themes" folder and run the create script there in this format (on linux or mac you'll need to make the .sh files executable)

c:\ liferay \ plugins \ themes>创建我的名字我的主题描述" linux/mac $> ./create.sh我的名字我的主题描述"

c:\liferay\plugins\themes >create my-name "My Theme Description" linux/mac $>./create.sh my-name "My Theme Description"

这将在名为my-name-theme的文件夹和其中的名为_diff的文件夹中创建骨架主题.

This will create a skeleton theme in a folder called my-name-theme and a folder within it called _diff.

在_diff文件夹内进行所需的任何修改. (除了更改WEB-INF中的属性文件外)

Make whatever modifications you want WITHIN THE _diff FOLDER. (except changes to the properties file within WEB-INF)

完成更改后,将在my-name-theme文件夹中运行"ant compile",并且sdk将按照其进度运行,并将.war文件吐出到sdk根目录中的"dist"文件夹中.您可以使用插件安装程序将其上传到网站上

Once you've made changes run "ant compile" from within the my-name-theme folder and the sdk will run through it's paces and spit out a .war file to the "dist" folder in the sdk root. You can upload this to the site using the plugin installer

或者...如果您将sdk配置为知道您的开发服务器在哪里,则可以从主题文件夹中运行"ant deploy",然后让liferay中的autodeploy魔术来完成工作.

OR ... if you configure the sdk to know where your development server is you can run "ant deploy" from the theme's folder and let the autodeploy magic in liferay do the work.

一旦安装了主题,只需使用管理页面"工具中的外观"标签对其进行分配.

Once the theme is installed just assign it using the "look and feel" tab in the "manage pages" tool.

提示:对custom.css文件进行大部分更改....使升级变得容易.

TIP : Make most of your changes to the custom.css file .... keeps things easy to upgrade.

提示:如果每次更改都这样做,CSS的开发确实会很慢..因此,如果您正在运行开发服务器,则在head标记的末尾之前添加一个样式标记,该标记指向您的_diffs/css文件夹. href ="file:///...../_diffs/custom.css".这样,您所做的任何编辑都将被编译到战争的下一个版本中,并且将覆盖当前安装的版本,而无需重新上传.请确保先删除链接,然后再将其放置在实时服务器上.

TIP : Development is really slow for CSS if you do this for every change .... so if you're running a dev server add a style tag just before the end of the head tag that points into your _diffs/css folder. href="file:///...../_diffs/custom.css". This way whatever edits you make will be compiled into the next version of the war and will override the currently installed version without reuploading. make sure to remove the link before you put it on a live server.

liferay.com文档很棒,并且有一个"themer's guide",我现在找不到指向该链接的链接,这使我开始工作.

The liferay.com documentation is great and there's a "themer's guide" i can't find the link to right now that got me started.

这篇关于需要在Liferay中更改模板样式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆