Andres Quinones

Ranch Hand
+ Follow
since Oct 09, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Andres Quinones

Dane I think that the problem is that the file /jsp/main.jsf doesn't exist what you need to reference is /jsp/main.jsp, also /jsp/AddApplication.jsf should be /jsp/AddApplication.jsp if your pages are jsp otherwise there should be your real file extension and not the mapping. For what are you using #addApp??
[ July 24, 2008: Message edited by: Andres Quinones ]
16 years ago
JSF
have you tried doing the mapping in the faces-config.xml and in the Managed Bean output the String in order to redirect you to the servlet you want?
16 years ago
JSF
Most of the cases implementing JSF you will find that they create one JSF Managed Bean per page. This make for some other developers to understand better the code. What probably you can do is to centralize all the Queries for the Orders in an OrderBean (EJB).

For the ORM Object, when you use JSF and Hibernate I think that the connection to the Database is closed after you return the objects to the View. Taking this in account probably is better that you update always the DB with the data captured from the view Layer and don't let it to modify it directly from the view through the ORM objects. It is possible but I don't think that could be a good practice.
16 years ago
JSF
This should work for you.

<h:outputLink value="#{ConfigLoginBean.logoutURL}"> <h:outputText value="Sign Out"/> </h:outputLink>
16 years ago
JSF
The <h:form> is only when you need to do requests to the server, otherwise you only need the <f:view>.

Good to hear that now is working. Any other questions don't hesitate to post.
16 years ago
JSF
Max the problem I found is that <h:outputText value="#{item.nomDetail}" /> should be <h:outputText value="#{item.detail}" />, because the attribute for the class Detail is detail and the getDetail() method is the one that will return the value. Otherwise you should have a method named getNomDetail() for your actual code to work.

Also don't forget the <f:view> and <h:form> tags for the page.

Hope this helps.
16 years ago
JSF
Bartek if you want to allow the field to have empty Strings you should remove the required attribute or set it false.
[ July 16, 2008: Message edited by: Andres Quinones ]
16 years ago
JSF
Charan I think that your Exception is being generated because you probably need to cast the Request to HttpServletRequest.


Hope this helps.
16 years ago
JSF
Gopi, you will not have to put 100,000 user in your xml file, because it is handle with roles for those users. I think is the best and cleanest way to manage your authorization process.

The filter is the other way but your application performance could decrease.
16 years ago
JSF
Muzzafar what is an stage? I don't understand your question.
16 years ago
JSF
I think is not very clear your question. Please be try to explain it better.
16 years ago
JSF
This can be done in different ways.

You can create a Filter that verifies every request if the user is logged in and redirect the user to a page if it is not logged in.

You can authorize acces to the pages through the web.xml in which you define which roles can access which pages, but for this you should read about JAAS here.

I think the best way to do this is through JAAS, is cleaner and is not reaaly hard to use it.

If you have any questions don't hesitate to ask.
[ July 15, 2008: Message edited by: Andres Quinones ]
16 years ago
JSF
I think that you should test the onclick event on the h:selectOneRadio because I think that the onchange is never called.

Hope this helps.
16 years ago
JSF
If I understand your problem is that you want to set a Session attribute in the onlcik event of an <a>?

If this is correct I just want to tell you that this is impossible because the javascript is executed in the client browser. In this case you should send the hostname as a request parameter, in order that the Server.do action could set this parameter in the session scope.

Hope this helps.
16 years ago
JSF
I think that this can solve your problem.

And the answer to your last post is that the Servlet is out of the FacesContext so it will be always null and the JSF Beans will not be out of the FacesContext.
[ July 11, 2008: Message edited by: Andres Quinones ]
16 years ago
JSF