title: Error on Installing Wordpress on Nginx
body: <p>I'm trying to install a wordpress site in a Linux VPS with LEMP Setup. So far I've done setting up the wordpress files and setting ownership for nginx user/group on the WP directory/files, but when I go to the address to access the installation page for WP (<a href="https://domain.tld/wp-admin/install.php" rel="nofollow">https://domain.tld/wp-admin/install.php</a>), I end up with a php file download instead.</p>
  
  <p>Here's my virtual host configuration for the WP site:</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>server {
   listen 80;
   server_name domain.tld;
   return 301 https://$server_name$request_uri;
  }
  
  server {
   listen 443 ssl;
  
   ssl on;
   ssl_certificate /directory/to/crt;
   ssl_certificate_key /directory/to/key;
   
   server_name domain.tld;
   root /var/www/html/domain.tld;
   index index.php index.html index.htm;
  
   location / {
      try_files $uri $uri/ /index.php?q=$uri&amp;$args;
   }
  
   rewrite /wp-admin$ $scheme://$host$uri/ permanent;
       
   error_page 404 /404.html;
   error_page 500 502 503 504 /50x.html;
  
   location = /50x.html {
      root /usr/share/nginx/html;
   }
  
   location ~ \.php$ {
      try_files $uri =404;
      fastcgi_split_path_info ^(.+\.php)(/.+)$;
      fastcgi_pass unix:/var/run/php5-fpm.sock;
      fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      fastcgi_index index.php;
      include fastcgi_params;
   }
  }</code></pre>
  </div>
  </div>
  </p>
  
  <p>EDIT: I tried it in Firefox, and it's acting differently than in Chrome. The install.php page instead ends up in an error page like this:</p>
  
  <blockquote>
    <p>An error occurred.</p>
    
    <p>Sorry, the page you are looking for is currently unavailable.
    Please try again later.</p>
    
    <p>If you are the system administrator of this resource then you should check the > error log for details.</p>
    
    <p>Faithfully yours, nginx.</p>
  </blockquote>