System at work is written in terrible terrible php, over the last few years PHP has come a long way, many of it's programmers haven't alas
That’s exactly my experience too. I’m attributing this to “the web curse”. Anything touched by the web is cursed with... I can’t even formulate it in few words, should be complex ancient magic.