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

[Question]关于网址的重定向 #223

Open
yabalababoom opened this issue Jan 21, 2023 · 2 comments
Open

[Question]关于网址的重定向 #223

yabalababoom opened this issue Jan 21, 2023 · 2 comments

Comments

@yabalababoom
Copy link

对于https://www.tieba.comforum.php?mod=viewthread&tid=567&extra=page%34&mobile=2这种网址,如何重定向到www.tieba.comforum.php?mod=viewthread&tid=567

我尝试使用正则表达式匹配符合规则的网址,我写的匹配规则如下:https://www.tieba.com/forum.php?mod=viewthread&tid=\d{6}&extra=page.*
在重定向至网址中,不知道怎么匹配原网址中的数字部分,求懂得大佬指点一二,万分感谢。

@jingjingxyk
Copy link

jingjingxyk commented Jan 24, 2023

@yabalababoom 给个例子,例子至少也应该是存在的例子吧!(你可以自己试一试,自己提供的案例)

你可能对正则表达式不太了解,那就学习一下呗

https://www.runoob.com/regexp/regexp-syntax.html

https://www.regular-expressions.info/refquick.html

@yabalababoom
Copy link
Author

你可能对正则表达式不太了解,那就学习一下呗

https://www.runoob.com/regexp/regexp-syntax.html

https://www.regular-expressions.info/refquick.html

谢谢,我参考了head editor中导入的规则,已经学会了

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