**List of steps to reproduce** (step by step, including full links if applicable):
Access these image URLs:
* https://upload.wikimedia.org/wikipedia/commons/thumb/1/1d/First_Ionization_Energy.svg/langzh-768px-First_Ionization_Energy.svg.png?20210520222611
* https://upload.wikimedia.org/wikipedia/commons/thumb/1/1d/First_Ionization_Energy.svg/langZh-768px-First_Ionization_Energy.svg.png?20210520222611
* https://upload.wikimedia.org/wikipedia/commons/thumb/1/1d/First_Ionization_Energy.svg/langzh-768PX-First_Ionization_Energy.svg.png?20210520222611
* https://upload.wikimedia.org/wikipedia/commons/thumb/1/1d/First_Ionization_Energy.svg/LANGZH-768PX-First_Ionization_Energy.svg.png?20210520222611
* https://upload.wikimedia.org/wikipedia/commons/thumb/1/1d/First_Ionization_Energy.svg/768PX-First_Ionization_Energy.svg.png?20210520222611
**What happens?**:
They all work. That is, they all produce the same PNG.
**What should have happened instead?**:
Only the first URL should have worked.
MW has a fixed format for `.../langzh-300px-...` that uses lowercase letters. We should never see anything but `lang` and `px`. The IETF langtag should be lowercased before inserting it into the URL. Permitting mixed case specification can lead to redundant entries in the client and server caches. Mixed case requests should err.
See also T310235.