[PATCH] Allows hyphens in variable names so can access hyphenated query vars
mdounin at mdounin.ru
Mon Aug 7 15:46:55 UTC 2017
On Mon, Aug 07, 2017 at 04:15:33PM +0100, Mark Ellis via nginx-devel wrote:
> Ok. How would you suggest accessing query parameters with hyphens?
> e.g. `?foo-bar=123`
> how would you get the value of foo-bar?
It is more or less trivial to extract anything from $args using a
regular expression. And the same applies to things like
"foo$bar=123", or any other fancy character you want to use in the
Alternative solution would be to avoid such naming, and use
aphanumeric plus "_" as directly accessible via $arg_* variables.
More information about the nginx-devel