【发布时间】:2020-12-07 05:27:20
【问题描述】:
如果我单击 portlet 按钮,它必须打开新选项卡并指向我调用的网站。 不幸的是,我无法做到这一点。我试过看煎茶讨论和东西,但我什么也没看到。当我单击按钮 portlet 时,下面是我的代码没有任何反应..
var btnProductsAndServices = {
xtype: 'portletbutton',
icon: '/test.png',
tooltip: 'Products & Services',
text: 'Products & Services',
click : window.open("https://www.w3schools.com")
};
我也尝试过这样做,但没有成功。
var btnProductsAndServices = {
xtype: 'portletbutton',
icon: '/test.png',
tooltip: 'Products & Services',
text: 'Products & Services',
click : {
handler: function redirect(){
window.open("https://www.w3schools.com")
}
}
};
【问题讨论】:
标签: javascript extjs sencha-touch sencha-architect