5 Replies Latest reply on Jul 27, 2012 5:20 AM by wuwei gu

    IE  脚本显示richfaces  未定义  ,请问有谁遇到过这个问题吗

    wuwei gu Newbie

      <!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:ui="http://java.sun.com/jsf/facelets"

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

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

                xmlns:t="http://myfaces.apache.org/tomahawk"

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

                xmlns:rich="http://richfaces.org/rich" xml:lang="cn" lang="cn">

      <h:head>

                          <link rel="stylesheet" type="text/css" href="../css/style.css" />

                    <link rel="stylesheet" type="text/css" href="../css/soft.css"/>

                    <meta http-equiv="Content-Type" content="text/xhtml; charset=utf-8"/>

      </h:head>

      <h:body>

       

                <f:event type="preRenderView" listener="#{cxBean.preHeadTable}"></f:event>

       

       

                <h:form id="tForm" prependId="false">

                           

                                

                                     <rich:extendedDataTable binding="#{cxBean.bodyTable}"

                                      var="row" onrowdblclick="value(this)"

                                      onRowMouseOver="this.style.backgroundColor='#F1F1F1'"

                                      onRowMouseOut="this.style.backgroundColor='#ffffff'">

                                     

                                                        style="height:308px; width:421px;" value="#{cxBean.rows}" id="etable">

                                   

                                        

                                     </rich:extendedDataTable>

                                

                        

                  </h:form>

       

       

       

                </h:body>

       

       

      </html>

        • 1. Re: IE  脚本显示richfaces  未定义  ,请问有谁遇到过这个问题吗
          Siva P Master

          Hi,

          Wrap the view into f:view,For Example do like below,

           

          <f:view>
          <h:head>
          </h:head>
          <h:body>
            <h:form>
             -------------------- UR CODE -------------------    
            </h:form>  
          </h:body>

          </f:view>
          </html>

           

          Thanks,

          siva

          • 2. Re: IE  脚本显示richfaces  未定义  ,请问有谁遇到过这个问题吗
            Brendan Healey Master

            It looks like we're going to have a game of "guess what the question is". It's best to use f:view contentType="text/html", this is

            needed for proper operation with webkit based browsers like chrome.

             

            Maybe do the preRenderView event like this because of this bug http://java.net/jira/browse/JAVASERVERFACES-2162 :

             

            <f:metadata>

              <f:viewParam name="dummy"/>

              <f:event type="preRenderView" listener="#{cxBean.preHeadTable}"></f:event>

            </f:metadata>

             

            Without the "dummy" line the listener is called once on the first ajax postback, twice on the second, etc...

             

            Probably deliberately omitted but you have no columns in your extendedDataTable so there will be no output.

             

            Regards,

            Brendan.

            • 3. Re: IE  脚本显示richfaces  未定义  ,请问有谁遇到过这个问题吗
              wuwei gu Newbie

              还是不行,在页面上不使用binging 属性,正常,使用binging 属性就报这个错误,好想是页面上没引入js那几个包(richfaces 用的)

              • 4. Re: IE  脚本显示richfaces  未定义  ,请问有谁遇到过这个问题吗
                Christian Peter Expert

                The google translator ist quite good: ;-)

                Title= "IE script shows richfaces is undefined, does anyone come across this problem."

                 

                the last post ... okay. I don't know:

                 

                "Or not, binging properties on the page, normal use of the the binging property, they reported the error, really want is not to introduce js on the page that several packages (richfaces used)"

                • 5. Re: IE  脚本显示richfaces  未定义  ,请问有谁遇到过这个问题吗
                  wuwei gu Newbie

                  问题解决了,手工导入如下文件

                   

                   

                  <link type="text/css" rel="stylesheet" href="/caiwu/rfRes/skinning.ecss.faces?db=eAG7mShzEgAFjAIg" />

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/jsf.js.faces?ln=javax.faces&amp;stage=Development"></script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/jquery.js.faces"></script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/richfaces.js.faces">

                                </script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/richfaces-base-component.js.faces">

                                </script><script type="text/javascript" src="/caiwu/javax.faces.resource/jquery.position.js.faces">

                                </script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/jquery.mousewheel.js.faces?ln=org.richfaces">

                                </script><script type="text/javascript" src="/caiwu/javax.faces.resource/inputNumberSpinner.js.faces?ln=org.richfaces"></script>

                                <link type="text/css" rel="stylesheet" href="/caiwu/rfRes/inputNumberSpinner.ecss.faces?db=eAG7mShzEgAFjAIg&amp;ln=org.richfaces" />

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/richfaces-queue.js.faces">

                                </script><script type="text/javascript" src="/caiwu/javax.faces.resource/richfaces-event.js.faces">

                                </script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/json-dom.js.faces?ln=org.richfaces">

                                </script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/jquery.effects.core.js.faces?ln=org.richfaces"></script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/jquery.effects.highlight.js.faces?ln=org.richfaces"></script>

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/JQuerySpinBtn.js.faces?ln=org.richfaces">

                                </script><script type="text/javascript" src="/caiwu/javax.faces.resource/calendar-utils.js.faces?ln=org.richfaces">

                                </script><script type="text/javascript" src="/caiwu/javax.faces.resource/calendar.js.faces?ln=org.richfaces">

                                </script><link type="text/css" rel="stylesheet" href="/caiwu/rfRes/calendar.ecss.faces?db=eAG7mShzEgAFjAIg&amp;ln=org.richfaces" />

                                <script type="text/javascript" src="/caiwu/javax.faces.resource/extendedDataTable.js.faces?ln=org.richfaces">

                                </script><link type="text/css" rel="stylesheet" href="/caiwu/rfRes/extendedDataTable.ecss.faces?db=eAG7mShzEgAFjAIg&amp;ln=org.richfaces" />

                                <link type="text/css" rel="stylesheet" href="/caiwu/rfRes/extendedDataTable.ecss.faces?db=eAG7mShzEgAFjAIg&amp;ln=org.richfaces" />

                  dingyi.JPG