3 ms·
What gave you the impression that WP was object-oriented?
by sethrin 9y ago
What gave you the impression that WP was object-oriented?
- pathartl 9y agoI guess you're right, it's really not. Some things are broken out into objects (WP_Post, WP_Term, etc) but I'm pretty sure that's only to utilize the PHP object cache
- sethrin 9y agoWP was itself released a little after PHP acquired classes; before that PHP was purely procedural. However, WP was a fork of an older project, and they kept things procedural in order to maintain backwards compatibility with the previous project. One cannot fault them for that decision in that context. However, apparently we are stuck with the consequences for the foreseeable future. On that basis, I wish that Google were not investing any further time and effort into what I sincerely hope can be described as the last popular procedural codebase in existence.