在学生页面的iframe链接处理中,移除hash部分里的userid参数,避免信息泄露或不必要的参数携带
@@ -1646,6 +1646,10 @@ const elementDone = async (element: any, slideIndex: number) => {
const parts = iframeSrc.split('#')
baseUrl = parts[0]
hashPart = parts[1]
+ // 去除hashPart中的userid参数
+ if (hashPart.includes('userid=')) {
+ hashPart = hashPart.replace(/[?&]userid=[^&]+/g, '').replace(/^&/, '?')
+ }
}
// 构建新的hash部分,添加参数