Closed silentHoo closed 6 years ago
nginx configuration is NOT a programing language, you'd better not putting complex logic in it。try lua-nginx-module。
in nginx configuration file, config commands run at several phase sequentially, "if" command run at REWRITE phase, "echo_foreach_split" command run at CONTENT phase, so , it not working as your expected。
Thanks @duzhe I've mixed it together, now I've found a working solution with lua.
I try to use
echo_foreach_split
to get each request header from the incoming request but only want to set one header on the response. Is this a bug or is this impossible this way?I tried it like this with:
Isn't this possible due to the underlying pointer structure used here? Or I'm doing it wrong?