Welcome! Log In Create A New Profile

Advanced

htaccess mal wieder

Posted by timofrenzel 
htaccess mal wieder
October 20, 2014 08:55AM
Stelle gerade um auf nginx zum testen.
Wie müsste das hier unter dem Nginx ausschauen?

<IfModule mod_rewrite.c>
Options -MultiViews

RewriteEngine On
#RewriteBase /path/to/app
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^ index.php [QSA,L]
</IfModule>




Danke
Timo
Re: htaccess mal wieder
October 20, 2014 10:00AM
if (!-f $request_filename){
set $rule_0 1$rule_0;
}
if (!-d $request_filename){
set $rule_0 2$rule_0;
}
if ($rule_0 = "21"){
rewrite ^/ /index.php last;
}
Re: htaccess mal wieder
October 20, 2014 11:37AM
http://nginx.org/en/docs/http/ngx_http_map_module.html

Don't use IF unless it is a single if.

---
nginx for Windows http://nginx-win.ecsds.eu/
Re: htaccess mal wieder
October 20, 2014 01:24PM
Versuch mal das in deinem location / {} Block:

try_files $uri $uri/ /index.php?q=$uri&$args;



Edited 1 time(s). Last edit at 10/20/2014 01:25PM by p.heppler.
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 173
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready