PHP-CLI script doesn't know $_SERVER when called by Apache?
-
24-06-2021 - |
Pergunta
here's a weird one:
I have a PHP-CLI script that runs just fine when called from a shell.
But when I have apache execute it via system()
it seems to forget about all the superglobals (or at least $_SERVER
) (they are 1
/true
).
Any ideas on where that's coming from?
Solução
The readline
extension was the badguy.
Deactivated it and it works.
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow