In the real world, you would refactor using the same general ideas instead of leaving the code as-is. I think this is one of the fundamental ideas in OOP to grasp. Maybe one of the biggest hurdles to clear in order to progress past script / markup languages. It's a challenge, but the "aha!" payoff is worth it. Plus, I think if you can grasp it, then it opens the door to idiomatic programming ideas / design patterns / and other abstract ways of thinking about how to solve problems as a programmer. When you read that programmers end up learning way more than one language, it's because they're all pretty similar and refactoring code into functions and objects is a big part of it. On the other hand, simpler things like wordpress will not require this sort of thing and you can definitely make a living with a simpler combination of wordpress, PHP, and SQL.