Programmatically set page template based on page ID
I needed to do something very similar for one of the plugins that I was developing. I registered two separate cpt’s during plugin activation, and each of those cpt’s should use a custom single template that I had bundled with the plugin code base. You should be able to do the same for page templates, … Read more