掲示板
How to read Velocity Template file in Liferay ?
13年前 に Gaurang Sheladia によって更新されました。
How to read Velocity Template file in Liferay ?
Regular Member 投稿: 159 参加年月日: 09/02/15 最新の投稿
Hi All,
Does anyone knows that how to read velocity template file from liferay plugin portlet?
Acutally i want to read one .vm file from my portlet.
Any suggestion would really appreciated.
Thanks in advance.
Thanks,
Gaurang
Does anyone knows that how to read velocity template file from liferay plugin portlet?
Acutally i want to read one .vm file from my portlet.
Any suggestion would really appreciated.
Thanks in advance.
Thanks,
Gaurang
13年前 に Gaurang Sheladia によって更新されました。
RE: How to read Velocity Template file in Liferay ?[SOLVED]
Regular Member 投稿: 159 参加年月日: 09/02/15 最新の投稿
Hi All,
Finally i have done it with Liferay API.
Regards,
Gaurang
Finally i have done it with Liferay API.
Regards,
Gaurang
13年前 に Simon Gołębiewski によって更新されました。
RE: How to read Velocity Template file in Liferay ?[SOLVED]
Regular Member 投稿: 246 参加年月日: 09/06/08 最新の投稿
Can you post how?
13年前 に Gaurang Sheladia によって更新されました。
RE: How to read Velocity Template file in Liferay ?[SOLVED]
Regular Member 投稿: 159 参加年月日: 09/02/15 最新の投稿
Hi Simon,
Yes i am definitely posting the solution.
I have done this with Liferay API as
Let me know if you need any more info.
Hope it will help.
Best,
Gaurang Sheladia
Yes i am definitely posting the solution.
I have done this with Liferay API as
InputStream is = MycustomPortlet.class.getClassLoader().getResourceAsStream("resource/MyInfo.vm");
Let me know if you need any more info.
Hope it will help.
Best,
Gaurang Sheladia
13年前 に Gaurang G によって更新されました。
RE: How to read Velocity Template file in Liferay ?
New Member 投稿: 16 参加年月日: 10/04/28 最新の投稿
Hi Gaurang,
A newbie question,
It is possible to check what all functions are available on custom velocity variables (variable that I define in the structure).?
eg. I created a structure with a Link (named "link") of type "Link to Page" and used
link.getUrl() to get the URL of the linked page. So I was wondering how to check of the other variables that are available with other types (eg. other then getUrl() as in this case).
A newbie question,
It is possible to check what all functions are available on custom velocity variables (variable that I define in the structure).?
eg. I created a structure with a Link (named "link") of type "Link to Page" and used
link.getUrl() to get the URL of the linked page. So I was wondering how to check of the other variables that are available with other types (eg. other then getUrl() as in this case).
13年前 に Gaurang Sheladia によって更新されました。
RE: How to read Velocity Template file in Liferay ?
Regular Member 投稿: 159 参加年月日: 09/02/15 最新の投稿
Hi Gaurang,
Are you talking about the Journal Structure Velocity variable that we are using for Article ?
Please clarify. I Will respond you ASAP.
Thanks,
Gaurang
Are you talking about the Journal Structure Velocity variable that we are using for Article ?
Please clarify. I Will respond you ASAP.
Thanks,
Gaurang
13年前 に Gaurang G によって更新されました。
RE: How to read Velocity Template file in Liferay ?
New Member 投稿: 16 参加年月日: 10/04/28 最新の投稿Gaurang Sheladia:
Hi Gaurang,
Are you talking about the Journal Structure Velocity variable that we are using for Article ?
Please clarify. I Will respond you ASAP.
Thanks,
Gaurang
Hi Gaurang,
Indeed, I was referring to the same. I was looking for what all functions are available on the variables we can create. getUrl() is one such function on type "Link to Page".
13年前 に vijay pandey によって更新されました。
how we include jsp/html file in template file(.tpl)
Junior Member 投稿: 44 参加年月日: 10/09/01 最新の投稿hi
Can we include any jsp/html file in .tpl file when we going to making template development ..
If yes the how we can include ..
Please help
Thanks in advance
13年前 に ankit yakkundi によって更新されました。
RE: How to read Velocity Template file in Liferay ?
Regular Member 投稿: 221 参加年月日: 10/03/05 最新の投稿
Hi Gaurang..
I have some issues with Templates in Liferay ,hoping that you can solve my doubts.
1) How to create JSP templates? There are no samples and documentation available for JSP-based templates in forums/technical documentation.
2) How to incorporate css/htmls received from a web designer into a velocity template; Assuming completely different look and feel. Do you have any examples?
These are the two issues i am facing, can i get ant sample code or documentation for the same and for learning velocity Template??
Thanks in advance..
Any idea or suggestions are welcome..
I have some issues with Templates in Liferay ,hoping that you can solve my doubts.
1) How to create JSP templates? There are no samples and documentation available for JSP-based templates in forums/technical documentation.
2) How to incorporate css/htmls received from a web designer into a velocity template; Assuming completely different look and feel. Do you have any examples?
These are the two issues i am facing, can i get ant sample code or documentation for the same and for learning velocity Template??
Thanks in advance..
Any idea or suggestions are welcome..
13年前 に Gaurav Jain によって更新されました。
RE: How to read Velocity Template file in Liferay ?
Regular Member 投稿: 145 参加年月日: 11/01/31 最新の投稿ankit yakkundi:
1) How to create JSP templates? There are no samples and documentation available for JSP-based templates in forums/technical documentation.
Even I am curious to know
ankit yakkundi:
2) How to incorporate css/htmls received from a web designer into a velocity template; Assuming completely different look and feel. Do you have any examples?
You can create vm templates just like html page (incorporating vm power).
For example:
<style>
your css goes here...
</style>
<div class="any_class">
#if ($link.getData() != "")
<a href="$link.getData()">
#end
<img alt="" src="$image.getData()" />
#if ($link.getData() != "")
</a>
#end
</div>
Or you can you can just use html tags with proper class and id attributes in vm files and add your css in theme.
10年前 に vijay pandey によって更新されました。
RE: How to read Velocity Template file in Liferay ?
Junior Member 投稿: 44 参加年月日: 10/09/01 最新の投稿
Thnaks but instead of using JSP template ,you can use .vm templates in liferay that is easily modifiable .