[WIP][HttpFoundation] fix pathinfo

WIP!

Tries to fix #6634. I also compared the methods with the changes done in the upstream ZF (where also some fixes happened).
`''` and `/` are technically the same URL as `''` does not really make sense.