ISPCONFIG3 + NGINX – WORDPRESS ISSUE

ISPCONFIG3 + NGINX – WORDPRESS ISSUE

source : by   Matt Cooper

Following on from the ISPConfig3 running on nginx tutorial I then came to installing a WordPress site within ISPConfig. Piece of cake, right?

So I went about the usual process of setting up a new site and database within the ISPConfig interface. Then I grabbed the latest WordPress (wget http://wordpress.org/latest.tar.gz), placing it in the correct location inside the “web” directory for this particular site. Ownership/permissions were then updated – everything as per normal in this environment.

I then enter the URL into my browser and low and behold the WordPress home page appeared. Great! Until I browsed to any other page within the test site:

ERROR 404 – Not Found!

From a considerable bit of Googling I found the following piece of code needs to be appended to your nginx Directives (ISPConfig > Website > Options)

  1. location / {
  2. try_files $uri $uri/ /index.php?$args;
  3. }

Restarted nginx and we’re back in business. All pages loading as they should.

Auteur de l’article : Sub

Laisser un commentaire

Votre adresse de messagerie ne sera pas publiée. Les champs obligatoires sont indiqués avec *

La modération des commentaires est activée. Votre commentaire peut prendre un certain temps avant d'apparaître.