代码:
A页面
<script type="text/javascript">
var ws = null;
mui.plusReady(function(){
ws = plus.webview.currentWebview();
ws.id = 'index';
// console.log(ws.id);
});
mui("body").on("tap", "a", function() {
var id = this.href;
mui.openWindow({
id: id,
url: id,
styles: 'webview_style',
extras:{
pageId:ws.id //扩展参数
},
show: {
aniShow: 'pop-in'
}
});
});
</script>
B页面
<script type="text/javascript">
mui.plusReady(function(){
var ws = plus.webview.currentWebview();
var page = plus.webview.getWebviewById(ws.pageId);
console.log(page);
});
</script>
打出log后page为null 

原文

 

相关文章:

  • 2021-09-10
  • 2021-11-07
  • 2022-02-26
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-19
  • 2021-11-19
相关资源
相似解决方案