Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
zahid khan
How to Put login portlet in a page without showing the other contents.
November 30, 2008 10:19 PM
Answer

zahid khan

Rank: Regular Member

Posts: 116

Join Date: July 30, 2008

Recent Posts

Hi all here i am trying to put my login portlet in a place so that when ever a user logs-in he should only see the login portlet there and not any other content like page name(welcome or home) or banner or footer any thing for that matter.

There should be an empty jsp page on which there is only log-in portlet at the center of the page.

Can any one help me achieve this. Any idea will be of great help.

Do i have to put a jsp page before from where i have to take the login details and forward the user to the concerned page or can i put i put the login portlet in web/guest/home page and can hide all other contents from that page (only).

Tell me which one is good and how to it.
Waiting for a reply.

Thanks in advance.
Tobias Amon
RE: How to Put login portlet in a page without showing the other contents.
December 1, 2008 3:39 AM
Answer

Tobias Amon

Rank: Liferay Master

Posts: 549

Join Date: August 8, 2007

Recent Posts

Hi,

I suggest, that you create a new portal theme for the login page. In this theme, simply remove anything that you don't need for portlet display. Your "portal_normal.vm" might look like this:
 1#if ($selectable)
 2        $theme.include($content_include)
 3    #else
 4        $portletDisplay.recycle()
 5
 6        $portletDisplay.setTitle($the_title)
 7
 8        $theme.wrapPortlet("portlet.vm", $content_include)
 9    #end


Then simply assign this simple theme to the login page.

kind regards
Tobias
zahid khan
RE: How to Put login portlet in a page without showing the other contents.
December 1, 2008 8:35 PM
Answer

zahid khan

Rank: Regular Member

Posts: 116

Join Date: July 30, 2008

Recent Posts

Thanks for the reply Tobias.

I am doing the same thing that u have mentioned above. but the problem is in some other place in the portal i am giving the user's permission to change the theme. And if the user selects that theme its not looking nice.

may be i have to stop that theme from appearing into the selection.

And one more thing is that we can have a jsp(index.jsp) as our first page and design it as required.
But i dont know how to do so.

Can u help in that?









Tobias Amon:
Hi,

I suggest, that you create a new portal theme for the login page. In this theme, simply remove anything that you don't need for portlet display. Your "portal_normal.vm" might look like this:
 1#if ($selectable)
 2        $theme.include($content_include)
 3    #else
 4        $portletDisplay.recycle()
 5
 6        $portletDisplay.setTitle($the_title)
 7
 8        $theme.wrapPortlet("portlet.vm", $content_include)
 9    #end


Then simply assign this simple theme to the login page.

kind regards
Tobias
Luc Pons
RE: How to Put login portlet in a page without showing the other contents.
December 3, 2008 10:45 PM
Answer

Luc Pons

Rank: Junior Member

Posts: 70

Join Date: December 3, 2008

Recent Posts

On your default page, you might remove the view permissions on the others portlets for the non-logged users...

But i'm guessing this wont affect the theme,
It will allow you to show only the login portlet