f:ajax`load`事件从未执行过?

时间:2013-07-02 16:10:01

标签: ajax jsf

我的onload事件未被触发。这是代码:

<html xmlns="http://www.w3.org/1999/xhtml" 
  xmlns:f="http://java.sun.com/jsf/core" 
  xmlns:h="http://java.sun.com/jsf/html"
  xmlns:p="http://primefaces.org/ui"
  xmlns:ui="http://java.sun.com/jsf/facelets">

<h:head>
    <meta http-equiv="content-type" content="text/html;charset=iso-8859-1"/>
    <title>#{txt.TXT_TITLE_WATCHFOLDERS}</title>
    <link rel="stylesheet" type="text/css" href="scripts/styles.css"/>       
    <link rel="shortcut icon" href="./images/favicon.ico"></link>
    <script src="./scripts/scripts.js" type="text/javascript"></script>

    <script type="text/javascript">
    function onLoadCallback(data) 
    {
        alert(data.status);
    }
    </script>

</h:head>

<h:body>

<f:ajax event="load" onevent="onLoadCallback"/>

<f:view>
    <h:form id="wfMgtForm" target="_top">
    ...

可能有什么问题,为什么onLoadCallback从未执行过?

0 个答案:

没有答案