requestcontrol icon indicating copy to clipboard operation
requestcontrol copied to clipboard

How do you setup redirection?

Open yaftyaft opened this issue 4 years ago • 9 comments

Hi guys, how do you setup a rule to redirect links?

eg

Visit: https://www.site1.com/go/abc.html Redirect To: https://site2.com/abc/

Visit: https://www.site1.com/go/xyz.html Redirect To: https://site2.com/xyz/

yaftyaft avatar Jul 21 '20 05:07 yaftyaft

Have you read the Request Control Manual 🙄

ChiefMikeK avatar Jul 29 '20 13:07 ChiefMikeK

so did anyone figure out how to do this?

renoder avatar Oct 09 '20 06:10 renoder

redirect

Pattern: www.site1.com /go/* Regex: {href/^https?:\/\/www\.site1\.com\/go\/(.+)\.html$/https://site2.com/$1/}

g2l2x avatar Nov 16 '20 16:11 g2l2x

redirect: http://sheyingtu-js.b0.aicdn.com/images/common/weixinewm.jpg
to:https://static.699pic.com/images/common/weixinewm.jpg

Regexp statement (\/\w+)(\/\w+[-_.]?\w+\.\w+)

The manual is no enough understandable and clear.

The big redirect problem, this: /images/common/weixinewm.jpg

redirect:https://sheyingtu-js.b0.aicdn.com/images/rj-iconv2.png
to:https://static.699pic.com/images/rj-iconv2.png

how to it?

CyberMan571 avatar Jul 29 '21 00:07 CyberMan571

As I understand you want something like Screenshot_2021-07-29_05-39-48-fs8 or Screenshot_2021-07-29_05-40-24-fs8

(both untested)

rusty-snake avatar Jul 29 '21 05:07 rusty-snake

image if one only is used, it works

{href/vo.aicdn.com/[protocol=https]img95.699pic.com} {href/sheyingtu-js.b0.aicdn.com/[protocol=https]static.699pic.com}

Thanks your reply How to redirect to URL that has same domain?

CyberMan571 avatar Jul 29 '21 18:07 CyberMan571

The "Redirect URL" is one URL (not "Redirect URLs"), so your rule will redirect http://sheyingtu-js.b0.aicdn.com/images/common/weixinewm.jpg (as example) to something like

http://sheyingtu-js.b0.aicdn.com/images/common/weixinewm.jpg http://[protocol=https]static.699pic.com/images/common/weixinewm.jpg

If you need to redirect from different origins to different origins you should create two rules. The "Redirect URL" syntax is linear, there are no flow control statements.

rusty-snake avatar Jul 29 '21 18:07 rusty-snake

redirect:https://sheyingtu-js.b0.aicdn.com/headImage/thumb100_1798744120200624112237.jpg
to:https://static.699pic.com/headImage/thumb100_1798744120200624112237.jpg

redirect:https://static.699pic.com/headImage/thumb100_1798744120200624112237.jpg
to:https://img95.699pic.com/photo/40195/3314.jpg_wh860.jpg
https://img95.699pic.com/photo/40195/3314.jpg_wh860.jpg https://vo.aicdn.com/photo/40195/3314.jpg_wh860.jpg
{href/vo.aicdn.com/[protocol=https]img95.699pic.com} {href/sheyingtu-js.b0.aicdn.com/[protocol=https]static.699pic.com}

Redirect Rule is matching both URLs the project need to improved Hope, I contribute to project in the future

CyberMan571 avatar Jul 29 '21 19:07 CyberMan571

i found a script for this extension, well 3 & 8 months old for some it seems to work.. but for me? not at all somehow.. image

{href/^(.*)$/https://wsrv.nl/?url=$1&output=webp&q=20} the script from this one post: https://pastebin.com/raw/fCX9Dd2P

i only see blocked requests but not redirected ones?

any idea what it could be? firefox

um6reon avatar Jul 19 '23 00:07 um6reon