ajax4jsf


Every time I make an Ajax request in JSF2 I am getting a new session bean,why?

时光总嘲笑我的痴心妄想 提交于 2020-01-11 09:56:26
问题 Hi I am getting a new session bean for every ajax request made to this Bean... Can any of you tell me why ? ...... imports ...... @Named(value = "userController") @SessionScoped public class UserController implements Serializable { private User current; private DataModel items = null; @EJB private br.com.cflex.itm.dataaccess.UserFacade ejbFacade; private PaginationHelper pagination; private int selectedItemIndex; public UserController() { } public Collection<Project> getMyProjectList(){

Can't “render/not render” a4joutputpanel rendered=“” “true/false” parameter by managed bean at JBoss Seam and Richfaces

你离开我真会死。 提交于 2020-01-07 07:15:10
问题 I'm new on seam and richfaces. I want to hide/show a4joutputpanel by rendered="" "true/false" parameter by giving Managed Bean.But ı'm taking this exception: com.sun.facelets.tag.TagAttributeException: /testscreen.xhtml action="#{testBean.renderActive(true)}" Not a Valid Method Expression: #{testBean.renderActive(true) } Can anyone help me about that? Here's my xhtml and managedbean codes: <a4j:commandButton action="#{testBean.renderActive(true)}" reRender="MyPanel" value="Start" /> <a4j

JSF h:CommandButton don't work with f:ajax?

社会主义新天地 提交于 2020-01-06 07:59:29
问题 I am trying to submit a form with the following code but it doesn't populate the fields in the bean: //input above <h:commandButton actionListener="#{transferenciaVagaBean.search()}" value="Search"> <f:ajax render="@form"/> </h:commandButton> Althoug, if I change the component to: //input above <a4j:commandButton actionListener="#{transferenciaVagaBean.search()}" value="Search" render="@form" /> It works perfect. Am I doing something wrong using h:commandButton? I tried to change from

What is the proper way to add a jquery plugin

隐身守侯 提交于 2020-01-03 04:04:13
问题 I am using JBOSS 3.01 and JSF 1.2 and RichFaces 3. What is the proper way to add a jquery plugin? <a:loadScript src="/scripts/jquery.cookie.js"/> or <script type="text/javascript" src="/scripts/jquery.cookie.js"></script> I get jQuery.cookie is not a function [Break On This Error] if(jQuery.cookie("cssswitch")) { When I try to use the a:loadScript. Our namespace is a: instead of a4j: 回答1: this one : <script type="text/javascript" src="/scripts/jquery.cookie.js"></script> ite a basic html

What is the proper way to add a jquery plugin

女生的网名这么多〃 提交于 2020-01-03 04:03:19
问题 I am using JBOSS 3.01 and JSF 1.2 and RichFaces 3. What is the proper way to add a jquery plugin? <a:loadScript src="/scripts/jquery.cookie.js"/> or <script type="text/javascript" src="/scripts/jquery.cookie.js"></script> I get jQuery.cookie is not a function [Break On This Error] if(jQuery.cookie("cssswitch")) { When I try to use the a:loadScript. Our namespace is a: instead of a4j: 回答1: this one : <script type="text/javascript" src="/scripts/jquery.cookie.js"></script> ite a basic html

JSF field highlighting with ajax posts?

北慕城南 提交于 2020-01-03 01:51:16
问题 I'm building on BalusC's solution to highlight and focus fields in JSF. My plan is to output a JSON array with ids and then have a method be called which will process this array. This works fine when I don't use <f:ajax/> Here is my phase listener solution: public void beforePhase(PhaseEvent event) { FacesContext facesContext = event.getFacesContext(); List<String> highlightFields = new ArrayList<String>(); Iterator<String> highlightFieldsItr = facesContext .getClientIdsWithMessages(); while

Is ajax4jsf dead? What other AJAX libraries for JSF are there?

*爱你&永不变心* 提交于 2020-01-02 07:10:52
问题 I am currently using the JBoss RichFaces JSF component library for the project I am working on. It works quite well in general, especially the AJAX support provided by ajax4jsf (A4J), but I find the usually very inflexible table-markup used for almost every component and all this "skin" stuff of RichFaces quite annoying. It would be nice if there were some components which just provided the functionality and only minimal markup/style. Originally I had planned to use ICEfaces, but that didn't

JSF ReRender support with selectBooleanCheckbox

隐身守侯 提交于 2020-01-01 06:18:06
问题 I have a JSF page on which I want to have a checkbox that, when clicked, will add/remove certain other form fields from the page. Here is the (simplified) code I currently have for the checkbox: <h:selectBooleanCheckbox title="showComponentToReRender" value="#{backingBean.showComponentToReRender}"> <a4j:support event="onsubmit" reRender="componentToReRender" /> </h:selectBooleanCheckbox> Here is the code for the component I want to hide: <h:selectOneMenu id="componentToReRender" value="#

Why usage of any a4j element in jsf add to page code second body and head tags?

爱⌒轻易说出口 提交于 2019-12-30 10:45:34
问题 In my jsf page code I have a structure similiar to this one : <frameset id="navframeset"> <frame name="navframe" src='<c:url value="TopNavigation.jsf"/>'/> <frameset> <frame name="leftframe" src='<c:url value="Test1.jsf"/>'/> <frame name="tabbedframe" src='<c:url value="Test2.jsf"/>' /> </frameset> In Test2.jsf i included following richfaces libraries : <%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%> <%@ taglib uri="http://richfaces.org/rich" prefix="rich"%> When I try to use any of

Validation of ViewParam and a4j:commandButton

与世无争的帅哥 提交于 2019-12-25 06:29:34
问题 I think i came across a bug of @ViewScoped with a4j:commandButton . I have a very complex form where all actions use a4j, except those that need to upload data. And depending on the order of the commands the validation of the viewParam breaks. Here is the working code: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java

工具导航Map