Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

is it possible to rewrite images? image store in /very/big/path/1.jpg , i want /img/1.jpg how can it be done?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

I think its easier to use the search here at first.

Rewrite1
Rewrite2

type: "nginx rewrite" to the search.

And there are many more posts where you can see how redirecting work with nginx ;).

Edit:

RewriteRule ^img/(.*)$ very/big/path/$1

something like this should work.

share|improve this answer
    
i need that img runs as php –  kusanagi Mar 10 '11 at 14:11
    
ok and where is the problem? You should edit your question and write it more detailed. On the sites that i have posted you can see how the rewrite works ;) when you searh here you will find an answer i am sure... that were only 2 question from many. –  Stony Mar 10 '11 at 14:16

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.