页面上的 XPage 按钮不会触发 [英] XPages Button on page will not fire

查看:30
本文介绍了页面上的 XPage 按钮不会触发的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个带有按钮的 XPage,无论代码多么简单,它都不会执行任何操作.没有出现错误,日志中没有任何内容显示为什么它不起作用.

I have an XPages with a button on it that will not do anything no matter how simple the code is. There are no errors appearing, nothing in the logs showing me why it does not work.

这是一个什么都不做的测试按钮:

Here is the test button that does nothing:

        <xp:button value="Print" id="button4">
            <xp:eventHandler event="onclick" submit="true"
                refreshMode="complete">
                <xp:this.action><![CDATA[#{javascript:context.redirectToPage("invoices_page1_doc.xsp");}]]></xp:this.action>
            </xp:eventHandler>
        </xp:button>

我没有看到代码不允许触发此按钮.

I do not see that code would not allow this button to fire.

我正在使用扩展库 ApplicationLayout 控件,该控件对其进行了一些自定义,但不确定为什么它会限制 XPage 上的按钮不起作用.

I am using the Extension Library ApplicationLayout control that has a few customizations to it, but not sure why it would limit a button on the XPage not to work.

我确实在页面源中注意到浏览器中似乎没有a href"或onclick"参数.Place Bar 操作已正确呈现,但 XPage 面板中的按钮似乎未呈现:

I did notice in the Page Source that it looks like there is no "a href" or "onclick" parameter in a browser. The Place Bar actions are correctly rendered, but a button in a panel on the XPage does not seem to render:

<button class="lotusBtn" type="button" name="view:_id1:_id2:OneUIMainAreaCallback:button4" id="view:_id1:_id2:OneUIMainAreaCallback:button4">Print</button>

我不知道还有什么地方可以开启这个功能.

I am not sure where else to turn on this.

感谢任何帮助.

谢谢!丹

推荐答案

事件处理程序使用 XSP 对象添加到页面末尾,因此不会有任何 JS 或 URL 与链接.如果该代码正在加载,请检查 Firebug.

The event handler is added at the end of the page using the XSP object, so there won't be any JS or URL with the link. Check in Firebug if that code is loading.

这篇关于页面上的 XPage 按钮不会触发的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆