var getUserInfoFromC = function() { var current_user = []; current_user.id = 0; current_user.name = ''; var cookie_user = document.cookie.match(".*_user=(.*)"); if (cookie_user != null) { cookie_user_matched = cookie_user[1].split('%2C'); current_user.id = cookie_user_matched[0]; current_user.name = decodeURI(cookie_user_matched[1]); } return current_user; }; 因为这里的cookie_user_matched变量为全变量,而且没有声明
添加回答
举报
0/150
提交
取消