The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Nginx Fix
Vbulletin5 is great... but if you running nginx i seen a few people having issues with it... well i got it running with rules below
Have fun Code:
location @php { try_files $uri =404; include /etc/nginx/fastcgi_params; fastcgi_pass unix:/var/run/php5-fpm.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_intercept_errors on; } rewrite ^/css.php$ /core/css.php last; rewrite ^/install/ /core/install/ last; if ($uri !~ ".(gif|jpg|jpeg|png|css)$"){ set $rule_2 1$rule_2; } if (!-f $request_filename){ set $rule_2 2$rule_2; } if (!-d $request_filename){ set $rule_2 3$rule_2; } if ($rule_2 = "321"){ rewrite ^/(.*)$ /index.php?routestring=$1 last; } rewrite ^/(admincp/)$ /index.php?routestring=$1 last; |
#2
|
||||
|
||||
There is a vhosts rewrite(s) included with the default package, did you not try it?
|
#3
|
||||
|
||||
hahaha well yer of course i did.. as i say there are many topics i read about vb5 and nginx... people saying vbulletins vhost file dont work... so i thought i would share my fix
|
#4
|
||||
|
||||
What exactly was wrong with the rewrite rules?
|
#5
|
||||
|
||||
They didnt work... as i say.. if you google you will find im not alone.. css messed up.. redirects didnt work correctly... mine works for me perfect... yours didnt.. i dont see what the problem is..
|
#6
|
||||
|
||||
I'm asking so we can fix the actual redirects for everyone.
You tried adding these rules? Code:
# configuration rules # legacy css being handled separate for performance location = /css\.php { rewrite ^ /core/css.php break; } # make install available from presentation location ^~ /install { rewrite ^/install/ /core/install/ break; } # any request to not existing item gets redirected through routestring location / { if (!-f $request_filename) { rewrite ^/(.*)$ /index.php?routestring=$1 last; } } # make admincp available from presentation location ^~ /admincp { if (!-f $request_filename) { rewrite ^/admincp/(.*)$ /index.php?routestring=admincp/$1 last; } } # process any php scripts, not found gets redirected through routestring location ~ \.php$ { # handles legacy scripts if (!-f $request_filename) { rewrite ^/(.*)$ /index.php?routestring=$1 break; } } |
Благодарность от: | ||
da_judge |
#7
|
||||
|
||||
i did try them as i stated previously.. nothing worked.. my rules did.. remember nginx can have different configs / setups on some distros... some rules work some dont.. xen has 0 issues though
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|