0 Replies Latest reply on May 26, 2011 2:27 AM by Muthu Kumaran

    Richfaces input text focus isssue IE

    Muthu Kumaran Newbie



      We are facing the focus while reRendering text box in IE.





              Test Text



              <div xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"

                  xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"

                  xmlns:a4j="http://richfaces.org/a4j" xmlns:rich="http://richfaces.org/rich">

                  <h:form id="form1">

                      <a4j:outputPanel id="PageARoot">

                          <a4j:keepAlive beanName="simpleBean" />

                          <h:outputText value="Infants:" />

                          <h:inputText id="text1" value="#{simpleBean.size}">

                              <a4j:support event="onblur" action="#{simpleBean.action}"


                                  reRender="MyContent" />


                          <h:panelGroup id="MyContent">


                              <a4j:repeat id="list" value="#{simpleBean.list}" var="item">

                                  <h:inputText id="text2" value="#{item}"

                                      onblur="javascript: alert(this.id);" />








      Bean Code:

      package beans;


      import java.util.ArrayList;

      import java.util.List;


      import javax.annotation.PostConstruct;


      public class SimpleStringBean {


          private List list;

          public List getList() {

              return list;



          public void setList(List list) {

              this.list = list;


          private int size;

          public int getSize() {

              return size;



          public void setSize(int size) {

              this.size = size;




          public void initialize(){


              list = new ArrayList();

              list.add(new Long(0));

              size = 1;


          private String text;


          public String getText() {

              return text;



          public void setText(String text) {

              this.text = text;



          public void action(){

              System.out.println("Action: " + text);

              list = new ArrayList();

              for(int i = 0; i < size; i++){

                  list.add(new Integer(0));













      When i tab out of the input text box "text1", the panel group is getting rerendered, but the focus is not setting to next input box. But i press on tab again, text2's onblur event is getting called. Which means the focus is set to one of the textbox, but focus is not visible or i am not able to type anything.


      Please help on this issue..