Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I tried this in the user.action file:

{ +redirect{s@http://www.google.*/search@https://encrypted.google.com/search@} }
.google.

But it doesn't work. My goal is to redirect from this:

http://www.google.*/searchBLA-BLA

to this:

https://encrypted.google.com/searchBLA-BLA

It could be de, pl, etc.; that's why I need the *.

share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

This rule works for me with TLD's .de, .pl:

{+redirect{s@^http://[^/]*/search\?q=([^&]*).*@https://encrypted.google.com/search?q=$1@}}
.google.*/search

You will find great examples how to use redirect in the Privoxy Action Files: redirect section documentation.

If you want to debug your rules enable debug 128 in the main configuration file.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.