I have setup a VPS with Ubuntu 14.04, Ajenti panel + Agenti V. Now I am trying to move an installation of Vanilla Forums from one server to another and it's giving me some headaches.
The forums open just fine, I can go through pages, .css files are loading but not .js files.
This is my nginx configuration in Ajenti:
try_files $uri $uri/ @rewrite;
location @rewrite {
rewrite ^/(.*)$ /index.php?p=$1;
}
location ~ .(js|jpg|png|css)(.+)$ {
root /srv/anunes/spacacores/;
}
The last part is my solution attempt. It does nothing.
Ok, let me answer this question without links then :)
.(js|jpg|png|css)(.+)$This regex says: Any character followed by one of
js|jpg|png|cssending with one, or more character(s).Lets change regex to:
\.(js|jpg|png|css)(.*)$and restart nginx and then try it again.Why? Probably your
jslinks has formatfile.js?somethingand css files does not, so nginx doesn't matchmain.cssat all because it has no character(s) aftercsspart (which is required by.+regex's part).