Projects accumulate a README section listing the commands nobody remembers: the linter with its config path, the test suite with its flags, the cache clear that has to…
PSR-4 autoloading is triggered by a class name PHP cannot resolve. Functions and constants have no such hook, so a helpers file has to be loaded eagerly —…
Registering a custom post type does not create its rewrite rules, so the archive 404s until permalinks are re-saved. The fix that circulates is flush_rewrite_rules() on init, which…
Before 5.6, a constant or a default parameter value had to be a literal. Anything computed — even multiplying two numbers you had already defined — was a…
A repository wrapping a single ORM, forwarding find to find, is indirection with nothing behind it — the abstraction has one implementation and will never have another, and…
Collecting a variable number of arguments used to mean func_get_args(), which hides the signature from anyone reading the function and from every IDE. 5.6 gives the language a…
In multisite, switch_to_blog() repoints the database tables and the uploads path. It does not reload the other site’s active plugins, its theme, or anything a plugin cached in…