- All requests (just not some folders) for that domain must be forwarded to the cgi-module (domain.url/ -> /cgi-bin/script.fcgi)
- Pathes have to be appended to the script (domain.url/path/to -> /cgi-bin/script.fcgi/path/to)
- Queries have also to be appended (domain.url?a=1 -> /cgi-bin/script.fcgi?a=1, domain.url/path/to?b=2 -> /cgi-bin/script.fcgi/path/to?b=2)
- Some subfolders have to be forwarded to another subfolder (domain.url/sub -> /ext/sub)
I tried with that:
- Code: Select all
RewriteEngine On
RewriteRule ^/sub/(.*)$ /ext/sub/$1 [L]
RewriteRule ^(.*)?$ /cgi-bin/script.fcgi/$1?%{QUERY_STRING} [L,QSA]
But unfortunately it isn't doing what I expect. The root is working, also the subfolder. But forwarding of a path and query string isn't working.