页面A里面有个showResult函数,这个函数将页面A中的localStorage数据写入seesionStorage保存,准备在页面B里面使用。
function showResult(){
var sname=[];
var time=[]
for(var i=0;i
Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
代码并没有问题,也能alert,异常out of memory应该是别的地方报错的
location.href是跳转,下面的alert肯定不知执行了,两个页面都引入这个js会一直跳形成死循环
代码没什么问题,你报的异常是内存不足,看看是什么情况