php - Trying to make sense of, and rewrite, nested if/else ← (PHP)