"Clearly and in detail" doesn't just mean the jOpenSim version in my mind.
As I told you above I am lost with all your different configurations.
However if you are on a recent server with php 7.4 I see no interest in downgrading your jOpenSim to 0.3.1.5 (and not 3.1.5).
I also advise you to start with a configuration as simple as possible. I mean without all the extra things you mentioned (like extra security stuff, vhost and cie ...).
Also, providing phpinfo is already good but testing the snippet code I provided is good too. I would like it to return TRUE as expected.
Honestly I do suspect problems in your various configurations, modifications, install / reinstalls, forward / backward version change. All good reasons for ultimately nothing to work properly.
I hope you understand me.