Tips & Tricks: Private Pages
November 19, 2010 1 Comment
As you probably know Liferay can automatically create private pages for new user. He can also use existing page as a template for new one. To do this you will need to:
1. Prepare your page using Sitemap, portles, themes etc.
2. Exports your page to lar file
3. Copy this lar to deploy/ (deploy/example.lar)
4. Add this to your portal-ext.properties
default.user.private.layouts.lar=${liferay.home}/deploy/example.lar
5. Restart application
You can also perform some tricks with this functionality. For example you want every user to have his own 3 web contents (resume, about me, my stuff). To do this just follow those steps:
1. Prepare your page using Sitemap, portles, themes etc.
2. Prepare your articles and publish them
3. Exports your page with all data to lar file
4. Copy this lar to deploy/ (deploy/example.lar)
5. Add this to your portal-ext.properties
default.user.private.layouts.lar=${liferay.home}/deploy/example.lar
6. Restart application
Now not only theme and pages are connected to private pages but Web content too. If there already is a web content with ID like on your template page Liferay will create new one changeing Owner to the user he is creating private page for. If there existssuch user in the system LR will publish those WC (Web contet) with that user as owner.
Thanks for sharing your thoughts on Antique Shop in Sherwood Arkansas.
Regards