[jboss-user] [JBoss Portal] - Re: getPreferences with JSF portlet

thomas.heute@jboss.com do-not-reply at jboss.com
Mon Oct 16 10:15:54 EDT 2006


Oups sorry i replied too quickly i missed that you were working on a JSF portlet.

On a JSF portlet you don't need to extend GenericPortlet and render() won't be called.

You need to pass a JSF page as parameter in portlet.xml in getSupprimer() you should access the preferences like this:


  | public String getSupprimer() { 
  |   PortletPreferences prefs = request.getPreferences();
  |   String parameter = prefs.getValue("suppression_pref",init);
  |   if (parameter.equals("true)) 
  |   {
  |     return "ok";
  |   }
  |   else
  |   {
  |     return "pas ok";
  |   }
  | }
  | 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3978547#3978547

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3978547



More information about the jboss-user mailing list