aspose file tools*
The moose likes JSF and the fly likes JSF navigation problems. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "JSF navigation problems." Watch "JSF navigation problems." New topic
Author

JSF navigation problems.

Marco Noronha
Ranch Hand

Joined: Oct 30, 2012
Posts: 50
Hi Guys,

I´m new at the forum, as I am new to JSF.
I didn´t like the navigation rules on faces.config no JSF.

I read somewhere that in JSF 2.0 ou 2.1 don´t know, that i don´t need
to specify the navigation rules for simples navigation.. Ex.:



and the framework will look for
index.xhtml
[and other extensions] on the dir.


Well, i´m trying to use it on my abstract controller where I have:

view/grupo/index.xhtml


and in my abstract controller - grupoController:



the problem is that i can´t seem to navigate
Am I commiting a sin ?

thank you


--EDIT:

Forgot the tell you the errors... Well, I keep getting this on my view:

Warning: This page calls for XML namespace declared with prefix br but no taglibrary exists for that namespace.
Unable to find matching navigation case with from-view-id '/view/grupo/index.xhtml' for action '#{grupoController.actionEdit}' with outcome 'view/grupo/form'Unable to find matching navigation case with from-view-id '/view/grupo/index.xhtml' for action '#{grupoController.actionEdit}' with outcome 'view/grupo/form'
The form component needs to have a UIForm in its ancestry. Suggestion: enclose the necessary components within <h:form>The form component needs to have a UIForm in its ancestry. Suggestion: enclose the necessary components within <h:form>
Warning: This page calls for XML namespace declared with prefix br but no taglibrary exists for that namespace.
Unable to find matching navigation case from view ID '/view/grupo/index.xhtml' for outcome 'view/grupo/index'Unable to find matching navigation case from view ID '/view/grupo/index.xhtml' for outcome 'view/grupo/index'


And I tried navigation on the menu, also didn´t work:

CODE


ERROR
Warning: This page calls for XML namespace declared with prefix br but no taglibrary exists for that namespace.
Unable to find matching navigation case from view ID '/view/grupo/index.xhtml' for outcome 'view/grupo/index'Unable to find matching navigation case from view ID '/view/grupo/index.xhtml' for outcome 'view/grupo/index'
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16145
    
  21

You really should fix this:


Apparently you have an "xmlns:br" somewhere in your View Definition (xhtml), but if there's a taglibrary for that namespace, it's not installed properly.

Your navigation problem, I think, is because you specified ""view/grupo/index" when you were already at the View whose URL was view/grupo/index. That means that the effective destination view would have been ""view/grupo/index/view/grupo/index" because you used a relative path. You should have specified an absolute path in such case:


Or a proper relative path:


Note that NO navigation will occur unless the action actually executes. If there are controls on the form that failed to validate, the action processing phase of the JSF lifecycle is suppressed.


Customer surveys are for companies who didn't pay proper attention to begin with.
Marco Noronha
Ranch Hand

Joined: Oct 30, 2012
Posts: 50
Tim Holloway wrote:You really should fix this:


Apparently you have an "xmlns:br" somewhere in your View Definition (xhtml), but if there's a taglibrary for that namespace, it's not installed properly.


I can´t find any page that has xmlns:br


Can you help me find? I´ll show you all of my pages declarations:





Tim Holloway wrote:

Your navigation problem, I think, is because you specified ""view/grupo/index" when you were already at the View whose URL was view/grupo/index. That means that the effective destination view would have been ""view/grupo/index/view/grupo/index" because you used a relative path. You should have specified an absolute path in such case:



Yeah, i really forgot that! But still, its not working ...
when i click on edit... it doesn´t go to the right page.

let me show you how I´m trying to navigate, maybe you have a better solution.





thanks for everything so far!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JSF navigation problems.