Welcome! Log In Create A New Profile

Advanced

nginScript filesystem access

April 13, 2017 04:16PM
Hello

We'd like to move a rather complicated multilingual website over to nginx. I must determine if we can handle the somewhat involved language based redirects in nginScript middleware (javascript).

At one point I must redirect based on whether or not a file exists. In the configuration file I could do this like so:

if (-f $realpath_root$url) {
...
}

However, that doesn't help me since all the redirection logic is in a javascript function.

How can I do that same test from within the javascript function rather than in the config file?
Subject Author Posted

nginScript filesystem access

Unsay April 13, 2017 04:16PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 272
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready