LAYOUT PlugIn
Layout Templates are ways of choosing how your portlets will be
arranged on a page. They make up the body of your page, the large area where
you drag and drop your portlets to create your pages. Liferay Portal comes with
several built-in layout templates, but if you have a complex page layout
(especially for your home page), you may wish to create a custom layout
template of your own.
Layout
Templates are the easiest plugins to create. They comprise only a few files
with simple table or CSS-based containers into which portlets can be dropped,
as well as a thumbnail image of what the layout looks like. This thumbnail is
displayed when the end user clicks Layout Template from the Dock menu.
Creating Layout
Templates #
Creation of
layout templates is done in a similar manner to the creation of portlets and
themes. There is a layouttpl folder inside the plugins SDK where all new layout
templates reside. To create a new layout template, you run a command in this
folder similar to the one you used to create a new portlet….
--The default
window state is normal (in Portlets)
-- Loading
process…
Theme àLayout à Portlet
--We can apply
the layouts only for pages
--All the
portlet IDs are mapped with pageLayoutIDs
Theme id à Page id à Page Layout id à Portlet id
Creation of
Layout (Custom Layout) :
New >
Liferay Project (select the the layout plugIn)> select ‘finish’.
In docroot
>, click on <projectname>.tpl
-Drag and drop
the rows and columns in the required structure whatever we want.
-Save, Deploy
and Run the server
We can see our
custom layout along with the default layouts in manage>page layout
No comments:
Post a Comment