因为angularjs是做单页应用,那我想_blank跳出一个新页面呢?这个页面当然要将主页面的数据带过来,该怎么做呢
1 回答

富国沪深
TA贡献1790条经验 获得超9个赞
方法有很多种。
把数据编码为字符串拼接在url上,比如
/page.html#data=woiqerunsdfkgjhsdfghdfjg
,在新页面里用location.hash
取出。如果不跨域,可以用
localStorage
。PostMessage
接口。
添加回答
举报
0/150
提交
取消