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

请问如何判断发生了跳转呢? #158

Open
ray0728 opened this issue Mar 23, 2023 · 1 comment
Open

请问如何判断发生了跳转呢? #158

ray0728 opened this issue Mar 23, 2023 · 1 comment

Comments

@ray0728
Copy link

ray0728 commented Mar 23, 2023

从response中似乎获取不到跳转后的URL,请问有什么办法判断访问的页面是否发生跳转吗?

@howie6879
Copy link
Owner

1、可以从301或者302状态码中获取location
2、或者返回是200,但是返回的内容是 script js代码,从里面提取目标跳转网页即可

和普通网页内容抓取面没区别

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants