Addon enhancements thread

Ideas and suggestions for how to improve the Warzone 2100 base game only. Ideas for mods go in Mapping/Modding instead. Read sticky posts first!
User avatar
dak180
Trained
Trained
Posts: 288
Joined: 01 Nov 2009, 23:58
Location: Keeper of the Mac Builds

Re: Addon enhancements thread

Post by dak180 »

I would suspect that it something covered by mod_rewrite rules or their equivalent.
Since we do not actually use Apache and mod_rewrite frustrates me to no end at the best of times, I have no real help that I can offer you with this; though if you want to make it not require mod_rewrite or something like it that would be very good.
User:dak180
Keeper of the Mac Builds
cybersphinx
Inactive
Inactive
Posts: 1695
Joined: 01 Sep 2006, 19:17

Re: Addon enhancements thread

Post by cybersphinx »

Rewrite rules:

Code: Select all

                rewrite ^/download/([a-z0-9/]*[^/]+)\.wz/?$ /index.php?p=download&file=/$1.wz last;
                rewrite ^/map/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=map/$1 last;
                rewrite ^/mod/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=mod/$1 last;
                rewrite ^/unapproved\/map/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=unapproved/map/$1 last;
                rewrite ^/unapproved\/mod/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=unapproved/mod/$1 last;
                rewrite ^/([A-Za-z0-9-]+)/?$ /index.php?p=$1 last;
                rewrite ^/([0-9.-]+)/?$ /index.php?p=$1 last;
                rewrite ^/([A-Za-z0-9-]+)/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=$1&sub=$2 last;
We want information... information... information.
User avatar
dak180
Trained
Trained
Posts: 288
Joined: 01 Nov 2009, 23:58
Location: Keeper of the Mac Builds

Re: Addon enhancements thread

Post by dak180 »

cybersphinx wrote:Rewrite rules:

Code: Select all

                rewrite ^/download/([a-z0-9/]*[^/]+)\.wz/?$ /index.php?p=download&file=/$1.wz last;
                rewrite ^/map/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=map/$1 last;
                rewrite ^/mod/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=mod/$1 last;
                rewrite ^/unapproved\/map/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=unapproved/map/$1 last;
                rewrite ^/unapproved\/mod/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=view&fullid=unapproved/mod/$1 last;
                rewrite ^/([A-Za-z0-9-]+)/?$ /index.php?p=$1 last;
                rewrite ^/([0-9.-]+)/?$ /index.php?p=$1 last;
                rewrite ^/([A-Za-z0-9-]+)/([A-Za-z0-9/-]*[A-Za-z0-9-])/?$ /index.php?p=$1&sub=$2 last;
Except that none of those are what is actually being used (nothing in any of the .htaccess files is).
User:dak180
Keeper of the Mac Builds
cybersphinx
Inactive
Inactive
Posts: 1695
Joined: 01 Sep 2006, 19:17

Re: Addon enhancements thread

Post by cybersphinx »

dak180 wrote:Except that none of those are what is actually being used (nothing in any of the .htaccess files is).
They're from the server config. But if you think they're useless I'll remove them, less clutter.
We want information... information... information.
User avatar
dak180
Trained
Trained
Posts: 288
Joined: 01 Nov 2009, 23:58
Location: Keeper of the Mac Builds

Re: Addon enhancements thread

Post by dak180 »

cybersphinx wrote:
dak180 wrote:Except that none of those are what is actually being used (nothing in any of the .htaccess files is).
They're from the server config. But if you think they're useless I'll remove them, less clutter.
All those files are from when we used to use Apache, since everything is now served by nginx none of those are now used, but I have no idea how many of those rules have been ported to the nginx config files.

We should keep them until we are sure that we do not need them as references.
User:dak180
Keeper of the Mac Builds
cybersphinx
Inactive
Inactive
Posts: 1695
Joined: 01 Sep 2006, 19:17

Re: Addon enhancements thread

Post by cybersphinx »

dak180 wrote:everything is now served by nginx
I know.
nginx config files.
That's where I got them from.
We want information... information... information.
User avatar
NoQ
Special
Special
Posts: 6226
Joined: 24 Dec 2009, 11:35
Location: /var/zone

Re: Addon enhancements thread

Post by NoQ »

Oh crap ... i should have installed nginx :doh:
Post Reply