Here is my current configuration:
- Operating System: Ubuntu 14.04
- Web Server: Nginx 1.4.6
- PHP Version: 5.5.9
- Moodle Version: 3.0
After successfully installing Moodle 3.0 through the browser, none of the CSS or JavaScript files are loading. The error logs from NGINX show the following errors:
2017/04/24 20:48:23 [error] 3277#0: *601 open() "/var/www/html/moodle/theme/image.php/clean/core/1493057621/moodlelogo" failed (20: Not a directory), client: 10.0.2.2, server: localhost, request: "GET /theme/image.php/clean/core/1493057621/moodlelogo HTTP/1.1", host: "localhost:8080", referrer: "http://localhost:8080/index.php"
...more error messages...
The issue seems to be that the path is misidentifying certain .php files as directories. Below is my server configuration:
server {
listen 8080;
server_name localhost;
# Root #
root /var/www/html/moodle/;
index index.php index.html index.htm;
location ~ \.php$ {
if (!-f $document_root$fastcgi_script_name) {
rewrite ^ 404;
}
include fastcgi_params;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
I have attempted the solutions provided in the links below, but they did not resolve the issue:
Solution 1
Solution 2
Unfortunately, none of these solutions were successful in fixing the problem...