Sponsor:

Server and Web Integrator
Link:
Kloxo-MR logo
6.5.0 or 7.0.0
Click for "How to install"
Donation/Sponsorship:
Kloxo-MR is open-source.
Donate and or Sponsorship always welcome.
Click to:
Click Here
Please login or register. 2024-06-05, 14:54:20

Author Topic: nginx rewrite for friendly ulr  (Read 3487 times)

0 Members and 1 Guest are viewing this topic.

Offline cmdman

  • Senior Member
  • *
  • Posts: 298
  • Karma: +1/-0
    • View Profile
nginx rewrite for friendly ulr
« on: 2014-10-25, 11:01:27 »
hi mr,

my forum guys said me to add Nginx Rewrites for Xenforo Friendly Urls, so they told us to add code inside nginx so please let me out on this where i can add this..

Nginx

To enable friendly URLs in Nginx, you must put the following in your server configuration:

Code: [Select]
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 =404;
fastcgi_pass    127.0.0.1:9000;
fastcgi_param   SCRIPT_FILENAME $document_root$fastcgi_script_name;
include         fastcgi_params;
}

Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: nginx rewrite for friendly ulr
« Reply #1 on: 2014-10-25, 11:19:47 »
Using Kloxo-MR 6.5.0 or 7.0.0?.

If using 6.5.0, copy /home/nginx/conf/defaults/globals/php-fpm.conf.tpl to custom.php-fpm.conf.tpl and then modified this file.

if using 7.0.0, the same way for /opt/configs/nginx/conf/defaults/globals/php-fpm_standard.conf.tpl and php-fpm_wildcards.conf.tpl
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline cmdman

  • Senior Member
  • *
  • Posts: 298
  • Karma: +1/-0
    • View Profile
Re: nginx rewrite for friendly ulr
« Reply #2 on: 2014-10-25, 12:47:27 »
iam using 6.50, iam not getting this path it self..
 /home/nginx/conf/defaults/globals/php-fpm.conf.tpl
looks this



some one told me to do like this.
http://www.xsimulator.net/xenforo-nginx-rewrite-rules-configuration/

Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: nginx rewrite for friendly ulr
« Reply #3 on: 2014-10-25, 13:10:24 »
Sorry, I mean ' /home/nginx/conf/globals/php-fpm.conf.tpl'
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline cmdman

  • Senior Member
  • *
  • Posts: 298
  • Karma: +1/-0
    • View Profile
Re: nginx rewrite for friendly ulr
« Reply #4 on: 2014-10-26, 03:25:42 »
are yu sure ..

as i dont see tpl files..


Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: nginx rewrite for friendly ulr
« Reply #5 on: 2014-10-26, 03:43:29 »
That mean 'php-fpm.conf' (not tpl).
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

 


Top 4 Global Search Engines:    Google    Bing    Baidu    Yahoo
Click Here

Page created in 0.027 seconds with 18 queries.

web stats analysis