|
本帖最后由 error 于 2024-11-4 09:13 编辑
随着论坛防火Q的升级,大部分丢crontab里面刷分的python,PHP脚本应该阵亡了,只能F12 console用js刷分了...
- function fetchUrls() {
- for (let i = 50770; i <= 50790; i++) {
- setTimeout(() => {
- fetch(`https://hostloc.com/space-uid-${i}.html`)
- .then(response => {
- if (response.ok) {
- console.log(`Fetched space-uid-${i}.html`);
- } else {
- console.error(`Failed to fetch space-uid-${i}.html: ${response.status}`);
- }
- })
- .catch(error => {
- console.error(`There was a problem with the fetch operation for space-uid-${i}:`, error);
- });
- }, (i - 50770) * 6000); // 每次请求之间间隔 6 秒
- }
- }
- fetchUrls();
复制代码
Powered by 
PS: 间隔时间可以自行尝试修改短些,前面用python requests get的时候貌似发现请求间隔时间低于5s会被ban,现在防火Q机制不清楚. |
|