Project

General

Profile

rewrite-once & rewite-if-not-file <- which is evaluated first

Added by laph over 6 years ago

May be a theoretical question, but assuming I use a rewrite-once AND rewrite-if-not-file instruction inside e.g. a HTTP['host'] Conditional. Which one is evaluated first in this case?


Replies (2)

RE: rewrite-once & rewite-if-not-file <- which is evaluated first - Added by stbuehler over 6 years ago

rewrite-once rules are executed before anything else. rewrite-if-not-file comes after constructing the physical filenames (docroot, alias handling), which comes after handlers that don't need a physical file (redirect, proxy, fastcgi with check-local => disable)

RE: rewrite-once & rewite-if-not-file <- which is evaluated first - Added by laph over 6 years ago

Huh! Of course! There's no need to resolve physical paths, when using rewrite-once! Sounds so logical, I could have found this answer by myself. :-)

Thanks!

    (1-2/2)