As a personal comment, not on behalf of being a Customizer, you can't utilize require_once(); in a template, as it breaks the Model-View-Controller which SMF is built upon (MVC).
It'd be a piece of cake to accomplish this using a source edit only, maybe even hooks, although that may be more tricky than just one source edit to accomplish this.
Furthermore, do you have this hooked in with who can change their theme, the permission?