Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Chuck Wyatt
Change default page to group or user page -- how hard can it be?
December 14, 2012 1:58 PM
Answer

Chuck Wyatt

Rank: New Member

Posts: 10

Join Date: October 17, 2011

Recent Posts

Right now for default login fields, we have left these blank so that once a user logs in, they end up on the main landing page for our test Liferay install, http://testliferay.edu/ as simple as that.

However, what I'd like to do is set up the default page so that it is, in effect: /web/username/home

That seems to be pretty difficult? If I plugin /web/guest/home into the GUI in portal-settings for default login page, I get a file not found upon login with a test user that has power-user as the default role. It is because they aren't "guest" role that it is throwing the error?

I'm including a screenshot of my test user page. That's essentially where I want each user to land upon login. Possible without editing class files, etc? I'm happy to add a line to the portal-ext.properties file, but it seems like we could just add it to the gui. I've attempted this line in portal-ext.properties, but so far, no cigar:
default.landing.page.path=/web/guest/home

Thanks,

Chuck

Dhrutika Vyas
RE: Change default page to group or user page -- how hard can it be?
December 15, 2012 10:11 AM
Answer

Dhrutika Vyas

Rank: Expert

Posts: 438

Join Date: February 9, 2009

Recent Posts

Hi Chuck,

It couldn't be possible without writing code. For landing to user's page you need to overwrite defaultlandingaction.java class.

You can set portlets on user page by two way either by properties or by usergroups.

Let me know if you want to achieve this solution.I will provide more details.

Regards,
Dhrutika
Chuck Wyatt
RE: Change default page to group or user page -- how hard can it be?
December 18, 2012 8:05 AM
Answer

Chuck Wyatt

Rank: New Member

Posts: 10

Join Date: October 17, 2011

Recent Posts

Hi Dhrutika,

Since receiving your message I've been reading more posts about how to do this, but maybe if you have more information about how to redirect to a users group page, that's more precisely what we're looking for. Ultimately we'll have users in groups based on their LDAP group membership, so that's a whole larger problem. But first I thought I would create some temporary groups, assign to our test users and see how that works to have them login to their group page.

So to redirect to a "group" page, I believe I need to make changes to defaultlandingaction.java class as well as portal-ext.properties, is that correct?

Thank you very much!

Chuck
Dhrutika Vyas
RE: Change default page to group or user page -- how hard can it be?
December 20, 2012 6:03 AM
Answer

Dhrutika Vyas

Rank: Expert

Posts: 438

Join Date: February 9, 2009

Recent Posts

Chuck Wyatt:
Hi Dhrutika,

Since receiving your message I've been reading more posts about how to do this, but maybe if you have more information about how to redirect to a users group page, that's more precisely what we're looking for. Ultimately we'll have users in groups based on their LDAP group membership, so that's a whole larger problem. But first I thought I would create some temporary groups, assign to our test users and see how that works to have them login to their group page.

So to redirect to a "group" page, I believe I need to make changes to defaultlandingaction.java class as well as portal-ext.properties, is that correct?

Thank you very much!

Chuck


Hi Chuck,

Yes you are correct. You can first how it works. You need to modify defaultlandingaction for this.

1. Create one user group with required pages and portlets.
2. In settings assign that user group name in default user association.
3. Modify below portal-ext.properties to modify landing action class.
4. landing action class update last path variable as /web/usercreenname/landing url.

Hope this helps.

Regards,
Dhrutika