4 Replies Latest reply on Feb 26, 2010 4:43 PM by Arbi Sookazian

    rich:modalPanel is scrolling page to the top

    Arbi Sookazian Master

      using richfaces-impl-3.3.1.GA.jar with Seam 2.1.1.GA

       

      When I click the link below to show the modalPanel, it scrolls vertically to the top of the screen and displays the modalPanel.  Why and how to fix that?  I've noticed that some of them don't do it, this one does so the user can't see the relevant section anymore in the page.  I have reproduced this behavior with FF 3.6 and IE 8.0.

       

      <h:outputLink value="#"
                                    id="historyLink"
                                    rendered="#{pageaction == 'view'}">
                          <h:graphicImage
                              value="/resources/images/icons/16x16/DataListButton.png"
                              style="cursor:pointer" />
                          <rich:componentControl
                              for="historyPanel"
                              attachTo="historyLink"
                              operation="show" event="onclick" />
                      </h:outputLink>

       

      <rich:modalPanel id="historyPanel"
                            minHeight="400"
                            minWidth="500"                     
                            rendered="#{pageaction == 'view'}">
               <f:facet name="header">
                   <h:panelGroup>
                       <h:outputText
                           value="#{messages['/restricted/merchant/current_billing_program.xhtml/header.panel.billingProgramHistory']}" />
                   </h:panelGroup>
               </f:facet>
               <f:facet name="controls">
                   <h:panelGroup>
                       <h:graphicImage
                           id="historyHidelink"
                           value="/resources/images/icons/14x14/close.png"
                           style="cursor:pointer" />
                       <rich:componentControl
                           for="historyPanel"
                           attachTo="historyHidelink"
                           operation="hide"
                           event="onclick" />
                   </h:panelGroup>
               </f:facet>
               <ui:include src="billing_program_history.xhtml"/>
           </rich:modalPanel>