5 Replies Latest reply on Jul 20, 2009 5:41 PM by Phil Wilson

    h:commandLink disabled when rich:datascroller next page

    Phil Wilson Apprentice

      Hey Guys,

      I have a strange issue.

      I have a h:commandLink and it works fine on the first page.

      When I select page 2 or any other page the h:commandLink does not work. I used FireBug with FireFox browser to inspect the code. I see the javascipt there it is just grayed out or disabled on all pages except page one.

      see the code below.

      <h:commandLink styleClass="phil" action="#{welcomeMemberViewForm.getMemberInfoAttrib_test}" immediate="true">
      <f:param id="memberId_str" name="memberId_str" value="#{welcomeMembersZip.memberId_str}"></f:param>


      This is the page footer...
      <f:facet name="footer">
       <rich:datascroller></rich:datascroller>
      </f:facet>






      this code works..
      <a class="phil" onclick="if(typeof jsfcljs == 'function'){jsfcljs(document.getElementById('f1'),{'f1:welcomeMembersZip:0:j_id_jsp_1293057100_131':'f1:welcomeMembersZip:0:j_id_jsp_1293057100_131','memberId_str':'8'},'');}return false" href="#">


      this code is grayed out below
      <td>
      <a class="phil" href="#" onclick="if(typeof jsfcljs == 'function'){jsfcljs(document.getElementById('f1'),{'f1:welcomeMembersZip:25:j_id_jsp_1293057100_131':'f1:welcomeMembersZip:25:j_id_jsp_1293057100_131','memberId_str':'172'},'');}return false"/>


        • 1. Re: h:commandLink disabled when rich:datascroller next page
          Ilya Shaikovsky Master

          try a4j:form instead of h:form and a4j:htmlCommandLink instead of h:commandLink. Just declare them fully the same as standard ones.

          read more at richfaces-demo for this components.

          • 2. Re: h:commandLink disabled when rich:datascroller next page
            Phil Wilson Apprentice

            Thanks for the reply,

            I tried this today and get the same issue. The command links do NOT work on the second page or any other page then first page.

            try a4j:form instead of h:form and a4j:htmlCommandLink instead of h:commandLink. Just declare them fully the same as standard ones.


            Any other ideal??

            Thanks
            Phil




            • 3. Re: h:commandLink disabled when rich:datascroller next page
              Phil Wilson Apprentice

              Hi ilya,

              Thanks for the response before..

              I have a question. Since I should not be using a div inside of a commandlink.

              how can put a on click on the DIV with the passed variables ??

              <a4j:htmlCommandLink styleClass="phil" action="#{welcomeMemberViewForm.getMemberInfoAttrib_test}" immediate="true">


              <a4j:htmlCommandLink styleClass="phil" action="#{welcomeMemberViewForm.getMemberInfoAttrib_test}" immediate="true">

              <f:param id="memberId_str" name="memberId_str" value="#{welcomeMembersZip.memberId_str}"></f:param>

              <h:panelGroup>

              <div onclick="" class="thumb" style="border: thin solid black">
              <h:graphicImage style="border: none" width="130"
              url="#{UpBundle.netFixImageServer}#{welcomeMembersZip.MEMBER_IMAGE_PATH}#{welcomeMembersZip.MEMBER_IMAGE_NAME}" >
              </h:graphicImage>
              </div>




              Thanks
              Phil


              • 4. Re: h:commandLink disabled when rich:datascroller next page
                Phil Wilson Apprentice

                Hi ilya,

                Thanks for the response before..

                I have a question. Since I should not be using a div inside of a commandlink.

                how can put a on click on the DIV with the passed variables ??

                <a4j:htmlCommandLink styleClass="phil" action="#{welcomeMemberViewForm.getMemberInfoAttrib_test}" immediate="true">


                <a4j:htmlCommandLink styleClass="phil" action="#{welcomeMemberViewForm.getMemberInfoAttrib_test}" immediate="true">

                <f:param id="memberId_str" name="memberId_str" value="#{welcomeMembersZip.memberId_str}"></f:param>

                <h:panelGroup>

                < d i v class="thumb" style="border: thin solid black">
                <h:graphicImage style="border: none" width="130"
                url="#{UpBundle.netFixImageServer}#{welcomeMembersZip.MEMBER_IMAGE_PATH}#{welcomeMembersZip.MEMBER_IMAGE_NAME}" >
                </h:graphicImage>
                </ d i v>



                • 5. Fixed --- Re: h:commandLink disabled when rich:datascroller
                  Phil Wilson Apprentice

                  Ok...

                  I fixed the issue...


                  Thanks
                  Phil