myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Gradecak <dan...@gradecak.com>
Subject Re: Portlet examples needed by portlet/MyFaces users
Date Thu, 14 Sep 2006 08:59:07 GMT
Hello,

I am not an expert but I use MyFaces and Tomahawk components inside 
portlets.

For standard MyFaces components I did not encounter problems. Anyhow, 
for Tomahawk components that need JS
I need to tweak a little. This was already discussed in this mailing list.

First I need to disable the extension check, because of the 
portlet/filter problem ...

<context-param>
        
<param-name>org.apache.myfaces.CHECK_EXTENSIONS_FILTER</param-name> 
        <param-value>false</param-value>
</context-param>

Then when I use a "JS" component I need to include the JS it needs in a 
portlet page

For example ...
<script type="text/javascript" 
src="/WEBAPP_CONTEXT/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11581259/accordion.HtmlAccordionPanelRenderer/dpdump.js"><!--
//--></script>

And then everything works fine ...

So I think that the only problem (at least for me) is because the 
scripts are included in the html head, which inside a protlet container 
is not allowed. There is no restriction in adding
the scripts wherever on the page, so it does not need to be in the head 
of the portal page. Each component could add its scripts lets say in the 
portlet page it is used. I saw that Ajax4Jsf
is doing that way ...

For now I did not want to implement any self made code, so this is the 
solution I choose. I think that the portlet spec 2 will solve this 
filter problem ... so probably everything will be O.K

Anyhow, I would like to hear that someone is using it in an easier way.

Regards,
Daniel

http://www.rest-art.hr/

Mike Kienenberger wrote:
> We've had a number of bugs posted by users of MyFaces who are also
> using Portlets.
>
> Would one of those users like to contribute some MyFaces portlet
> examples to aid us in fixing and debugging your issues?   I don't
> think any of the currently-active MyFaces committers are using
> portlets, so it's hard for us to see your problems or test patches.
>
> Thanks!


Mime
View raw message