with f:convertNumber , groupingUsed property can be used to remove comma or dot in numbers when numbers are greater than 1000.
#SelfNote
with f:convertNumber , groupingUsed property can be used to remove comma or dot in numbers when numbers are greater than 1000.
#SelfNote
A nice answer from the correct guy for ‘JSF Sucks’ issues:
http://weblogs.java.net/blog/edburns/archive/2010/01/22/analysis-peter-thomass-jsf-critical-rant
Hi,
if you want to make a form submit with executing your action in JSF, what you can do is as follows:
<h:commandButton id="hidden" style="width:0px;height:0px;border:none" action="#{bean.doSth}" />
this is a hidden button and will execute your method.
Btw, if you use style=”display:none;”, it does not work in ie 🙂
Hi,
currently the following is my favorite tech stack while developing a web application:
JBoss EL is a powerful tool if you are using JSF. You can pass parameters to methods in JSF with it. It is my favorite tool right now while developing with JSF. I thought it was coming with Seam only, I mean I thought that you cannot use it without Seam but then in a PrimeFaces-Spring-Hibernate project I needed this. It turns out that you can use JBoss el w/o Seam also and it is very easy to integrate.
1. Just download JBoss EL jar to your web-ing/lib folder, or add it as a dependency in your pom.xml file ( if you’re using maven)
and put this in your web.xml file:
<context-param>
<param-name>com.sun.faces.expressionFactory</param-name>
<param-value>org.jboss.el.ExpressionFactoryImpl</param-value>
</context-param>
that is it. now you can do a lot of tricks like :
<ui:repeat var="day" value="#{bean.user.getWorkingDays(bean.periodStartDate, bean.periodEndDate)}">
<p:commandButton value="#{day}" action="#{bean.selectDay(day)}"/>
</ui:repeat>
yes, like above all kind of tricks can be done now.
The best way to pass a value when navigating from one page to other ( right now ) is
<f:setPropertyActionListener value="#{someValue}" target="#{yourBean.yourValue } "/>
where yourBean will be the bean that is used in the page that you are navigating to.
you should use JSF 1.2 by the way.
Note to myself:
never forget to add equals and hashcode method when using a h:selectOneMenu and when making a double combo
or you will be having ‘value is not a valid option ‘ errors.
A very nice set of tricks from Venkat Sadasivam, when working in a JSF Project