This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<#-- | |
There are several ways of accesing the data stored in a structured web content, | |
it can be accesible by name, if the field is a main level item, | |
it can be a repetible content and so we have to access it's siblings, | |
and it can be a nested field and we have to access it through the parent. | |
--> | |
<#-- Structure Example Source (reduced and simplified) | |
I have deleted a lot of lines to make a Proof of Concept |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- In the file named liferay-look-and-feel.xml | |
inside a theme we can define different color schemes --> | |
<look-and-feel> | |
<compatibility> | |
<version>7.0.0+</version> | |
</compatibility> | |
<theme id="theme-generator-test" name="Theme Generator Test"> | |
<template-extension>ftl</template-extension> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Liferay 7 bookmarks</title> | |
</head> | |
<body> | |
<a href="https://docs.liferay.com/portal/7.0-ga3/javadocs/portal-kernel/allclasses-noframe.html">Liferay 7 Javadoc</a> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<#-- We have access to certain variables within a template (freemarker) --> | |
<#assign articleId = .vars['reserved-article-id'].data /> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<#-- Liferay info on templates: https://dev.liferay.com/discover/portal/-/knowledge_base/7-0/designing-uniform-content --> | |
<#-- There is more than just a way of doing this: --> | |
<#-- Option 1 --> | |
<#assign journalArticleLocalService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService")> | |
<#if entries?has_content> | |
<#list entries as curEntry> | |
<#assign article = curEntry.getAssetRenderer().getArticle() /> | |
<#assign model = objectUtil("com.liferay.portal.kernel.portlet.PortletRequestModel", renderRequest, renderResponse) /> |