Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Mon Apr 02, 2012 2:18 pm 
Offline

Joined: Mon Apr 02, 2012 2:15 pm
Posts: 1
Hi all,

I've a Glype proxy and I want to rewrite the URL's. All URLs on the page are automatically converted to:
Code:
http://proxy.com/browse.php?u=[URL HERE]

Example: If I go to /browse on The Pirate Bay on my proxy I want to convert the URL from this:
Code:
http://proxy.com/tpb/browse.php?u=http%3A%2F%2Fthepiratebay.se%2Fbrowse&b=0


To this:
Code:
http://proxy.com/tpb/browse


Also if i go to:
Code:
http://proxy.com/tpb/browse.php?u=http%3A%2F%2Fthepiratebay.se%2Ftop&b=0


Then I want to convert to:
Code:
http://proxy.com/tpb/top


As you can see, the whole part:
Code:
browse.php?u=http%3A%2F%2Fthepiratebay.se%2F


Is gone (and the `&b=0` what is behind the URL). And it has the same domain structure as The Pirate Bay.

I've tried something like this, in the .htaccess file:
Code:
location /tpb/ {
    rewrite ^/browse.php?u=(.*)$ /$1? last;
    break;
}


But it is not working. Somebody has an answer? An other function is also welcome. (Such as `fastcgi_split_path_info` or something else what is compatible with nginx)

(If you want see a example go to tpb.piratenpartij.nl but I'm not sure if they are using Glype)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group