Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在中国大学慕课网页上脚本不会正常运行 #232

Closed
xiaoxizi98 opened this issue Sep 14, 2023 · 11 comments
Closed

在中国大学慕课网页上脚本不会正常运行 #232

xiaoxizi98 opened this issue Sep 14, 2023 · 11 comments
Labels
bug Something isn't working

Comments

@xiaoxizi98
Copy link

用一个匹配所有网页的弹窗脚本进行测试,在其他网页都会弹窗但在中国大学慕课不会弹窗,且脚本猫显示脚本已经生效。是不是有网页白名单,在白名单网页上不运行脚本。

@CodFrm
Copy link
Member

CodFrm commented Sep 14, 2023

发一下脚本与链接

也可能与对应的网站有关系

@CodFrm
Copy link
Member

CodFrm commented Sep 14, 2023

其它会弹窗的网页的链接有么?

要不问一下作者,我看其它网页也没有弹窗

@xiaoxizi98
Copy link
Author

上面的脚本不是弹窗的脚本,是从该脚本发现在慕课页面不能执行。弹窗脚本是我自己写来测试用的,您可以试一下。


// ==UserScript==
// @name 测试
// @Version 1.0.0
// @match ://
// ==/UserScript==

alert(123)


@CodFrm
Copy link
Member

CodFrm commented Sep 14, 2023

也可以的

image

@CodFrm
Copy link
Member

CodFrm commented Sep 14, 2023

直接在页面上刷新 看看可不可以?

@xiaoxizi98
Copy link
Author

我刚也试了一下 不登录状态下是可以弹窗,登录之后进入课程界面就不会弹窗。

@xiaoxizi98
Copy link
Author

应该是匹配 https://www.icourse163.org/learn/* 才不执行,不登录的话网页跳转到 https://www.icourse163.org/course/USTC-1463123169?tid=1470908445 所以可以弹窗了。

@CodFrm
Copy link
Member

CodFrm commented Sep 14, 2023

https://www.icourse163.org/learn/USTC-1463123169?tid=1470908445#/learn/announce

像这样?好像是的,我排查一下

@CodFrm CodFrm reopened this Sep 14, 2023
@CodFrm CodFrm added the bug Something isn't working label Sep 14, 2023
@CodFrm
Copy link
Member

CodFrm commented Sep 17, 2023

是脚本运行框架注入速度导致的这个问题,哥哥试试这个版本可不可以
https://github.com/scriptscat/scriptcat/actions/runs/6211417667

@CodFrm CodFrm closed this as completed Sep 17, 2023
@xiaoxizi98
Copy link
Author

这个版本可以了👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants