Deebs
Well-known member
The only issue with your configuration is that everything will now get routed to /xf/index.php as that will always exists. An example:Okay NginX abusers - time to get out the text editors as you all likely have to make this change.
This is the current suggested nginx conf as per here
The problem you'll run into with this is that any urls at your site that end with .php will be treated as absolute and xenForo will not internally route the requests, what will happen instead is you'll either get a blank page or a 404.
http://example.com/members.php <----- If you're running NginX and this link doesn't work for you then you need to make the following change.
Find
Directly under it putCode:location ~ \.php$ {
Code:try_files $uri /xf/index.php =404;
So simple, if the location/file ending .php doesn't exists route it back through index.php and ta da xf is now handling php correctly.
The complete copy and paste code is attached.
Code:location /xf/ { try_files $uri $uri/ /xf/index.php?$uri&$args; index index.php index.html; } location /xf/internal_data/ { internal; } location /xf/library/ { internal; } location ~ \.php$ { try_files $uri /xf/index.php =404; fastcgi_pass 127.0.0.1:9000; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; }
Remember to change "/xf" to your paths.
http://the-sps.org/doiexist will give a XF error page.
http://forums.freddyshouse.com/doiexist will give a generic 404 page and not be processed via XF.