Fórumok

renderURL of nested Portlet doesnt work on Websphere

Denis Dik, módosítva 9 év-val korábban

renderURL of nested Portlet doesnt work on Websphere

New Member Bejegyzések: 7 Csatlakozás dátuma: 2014.08.11. Legújabb bejegyzések
Hello,

I developed a portlet which gets called on condition via <liferay-portlet:runtime portletName="2903"></liferay-portlet:runtime> inside another portlets view.jsp
Explanation: PortletA::view.jsp does check which Theme is currently applied and then either loads PortletB or keeps processing its own code.

It's a mobile version of the message boards portlet and does work on Tomcat 7.0.27 which I use for development.

Problem: The live server is Websphere and after the deployment process all links that were created with renderURL taglib don't work, e.g. after a click the same page just gets reloaded and nothing happens. The tags look like this:

<portlet:renderurl var="editURL">
			<portlet:param name="struts_action" value="/mobile_message_boards/edit_message" />
			<portlet:param name="redirect" value="<%= currentURL %>" />
			<portlet:param name="messageId" value="<%= String.valueOf(message.getMessageId()) %>" />
		</portlet:renderurl>


Observed:
The posted snippet does produce a working link on Tomcat but not on Websphere. When I use <portlet:actionURL>instaed of <portlet:renderURL> it also works on Websphere.
When I add the portlet individually/directly into a page the renderURL do work again, but then I lose my condition which portlet should be loaded. emoticon
I believe it has something to do with some config rights for creating/calling renderURL of portletB inside portletA. I didn't find any viable solution for this issue.

Does anyone know a solution or a workaround?

Kind Regards,
Denis Dik
Denis Dik, módosítva 9 év-val korábban

RE: renderURL of nested Portlet doesnt work on Websphere

New Member Bejegyzések: 7 Csatlakozás dátuma: 2014.08.11. Legújabb bejegyzések
Push, please help, I just can't find the solution to this issue.

Is there maybe another option to implement a logic that can switch out portlets?
thumbnail
Thomas Berg, módosítva 9 év-val korábban

RE: renderURL of nested Portlet doesnt work on Websphere

Regular Member Bejegyzések: 131 Csatlakozás dátuma: 2009.09.07. Legújabb bejegyzések
Hi Denis,
I don't have a solution, just chiming in an saying that I've got the same problem with the original MessageBoards portlet.

One difference is that I'm not using "Nested Portlets" application from Liferay. I'm using a custom portlet with tabs that embeds some portlets including MessageBoards. Perhaps this has something to do with the friendly url mapping "-/message_boards" ?

I tried adding

<private-request-attributes>false</private-request-attributes>
<private-session-attributes>false</private-session-attributes>

to liferay-portlet.xml (as they are set for the Nested Portlets application but that, of course, did not make any difference. Other portlets, like "Site Members Directory" works in my custom nested portlet.

I created an issue on this: https://issues.liferay.com/browse/LPS-52229

Regards Thomas