2

I can't find in docs how I can do negative statement like one below:

if !($some_var) {
  ... enter here if $some_var doesn't exist or empty
}

I know that I can check that the variable is exits using the if statement:

if ($some_var) {
  ...
}

But I can't find how to do if not statement

Is it possible for NGINX?

Flimzy
  • 68,325
  • 15
  • 126
  • 165
Klimbo
  • 1,178
  • 2
  • 10
  • 31

1 Answers1

0

Try this:


if($var = false) {
     ....
}