Thanks for you're help but still not working. I tried
a lot of different combination of navigation rule but
it's never working. My problme is not navigation but
more in the action thing. I think I need to force JSF
to send the action to a specific page, how can I do
that?
Here is my faces-config.xml:
<navigation-rule>
<from-view-id>*</from-view-id>
<navigation-case>
<from-outcome>navEtablissement</from-outcome>
<to-view-id>/etablissement.tiles</to-view-id>
</navigation-case>
<navigation-case>
<from-outcome>navMairie</from-outcome>
<to-view-id>/mairie.tiles</to-view-id>
</navigation-case>
<navigation-case>
<from-outcome>navDeclaration</from-outcome>
<to-view-id>/declaration.tiles</to-view-id>
</navigation-case>
</navigation-rule>
Here it's my command button in a jsf page of my
tile(composed of 4 pages):
<h:commandLink id="lkE" action="#{mairie.addE}"
immediate="true">
<h:outputText value="Add"/>
</h:commandLink>
and here it's the method called of my managed bean
used:
public String addE() {
.....
return "sucess";
}
--- Matthias Wessendorf <[EMAIL PROTECTED]> a
écrit :
> fast shot,
>
> -suround your button w/ <h:form>
> -ensure that you are using *global* navigation like
> <navigation-rule>
> <from-view-id>*</from-view-id>
> <navigation-case>
> <from-outcome>nav_page1</from-outcome>
> <to-view-id>/page1.jsp</to-view-id>
> </navigation-case>
> <navigation-case>
> <from-outcome>nav_page2</from-outcome>
> <to-view-id>/page2.jsp</to-view-id>
> </navigation-case>
> <navigation-case>
> <from-outcome>nav_page3</from-outcome>
> <to-view-id>/non-tile.jsp</to-view-id>
> </navigation-case>
> <navigation-case>
> <from-outcome>nav_page4</from-outcome>
> <to-view-id>/page4.jsp</to-view-id>
> </navigation-case>
> </navigation-rule>
>
>
> On 2/15/06, CHAMBAZ Alexandre
> <[EMAIL PROTECTED]> wrote:
> > Hi everybody,
> >
> > I'm develloping a JSF Site with Tiles (from
> Struts)
> > using the Tomahawk (I'm new in JSF programming
> >
>
)org.apache.myfaces.application.jsp.JspTilesViewHandlerImpl
> > support. The tile thing is working well. But when
> I'm
> > doing action in a jsf (with a command button) it's
> not
> > working.
> >
> > Here what I've got:
> >
> > body.jsp : <h:commandButton value="add"
> > action="#{bean.add}"/>
> > this page works well alone adding an element to a
> > table
> >
> > menu.jsp : a page with a tree2 object from
> tomahawk
> > working well also
> >
> > but if I use a tile to structure my design with
> the
> > tomahawk support, the action is not executed so
> nothin
> > is add.
> >
> > Here is my tile definition:
> > <definition name="main.tiles"
> extends="main.layout" >
> > <put name="body" value="/pages/body.jsp"
> />
> > <put name="menu" value="/pages/menu.jsp"
> />
> > </definition>
> >
> > Is there someone who could help me? is this had
> > already be solved?
> >
> >
> >
> >
> >
> >
> >
>
___________________________________________________________________________
> > Nouveau : téléphonez moins cher avec Yahoo!
> Messenger ! Découvez les tarifs exceptionnels pour
> appeler la France et l'international.
> > Téléchargez sur http://fr.messenger.yahoo.com
> >
>
>
> --
> Matthias Wessendorf
> Zülpicher Wall 12, 239
> 50674 Köln
> http://www.wessendorf.net
> mwessendorf-at-gmail-dot-com
>
___________________________________________________________________________
Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs
exceptionnels pour appeler la France et l'international.
Téléchargez sur http://fr.messenger.yahoo.com