This content has been marked as final.
Show 3 replies
-
1. Re: CMS Portlet and indexpage problem
keletappi Mar 16, 2006 11:18 AM (in response to keletappi)I clarify a bit.
When using preferences it would be possible to set indexpage in *-object.xml deployments without defining new portlet.<deployment> <if-exists>overwrite</if-exists> <instance> <instance-name>CMS_SupportPage</instance-name> <component-ref>portal.CMSPortlet</component-ref> <preferences> <preference> <name>indexpage</name> <value>/default/support.html</value> <read-only>false</read-only> </preference> </preferences> </instance> </deployment>
-
2. Re: CMS Portlet and indexpage problem
roy.russo Mar 16, 2006 11:41 AM (in response to keletappi)This feature was added to 2.4. Thanks.
-
3. Re: CMS Portlet and indexpage problem
hr_k Apr 6, 2006 4:31 PM (in response to keletappi)Thanks for you advice - I had the same problem.
To make it work with perferences on portal v2.2, one need to add the flowing code to CMSPortlet.java.
Insert this in the beging of doView:String tmpIndexpage = req.getPreferences().getValue("indexpage", LINK_MODE_PORTLET); if(!LINK_MODE_PORTLET.equals(tmpIndexpage)) { log.info("sets the new cms page to "+tmpIndexpage ); indexpage=tmpIndexpage; }
This why you change the value of the indexPage (which is set at init), to the on from the portlet perference.
Of course a rebuild of the source is needed.