How to define template routes for a custom element type So I'm working on a prototyping plugin that has its own element type for pages.  My hope was to have a single _page.html template and much like entries or categories be able to tell Craft to map the routes for all the elements URIs to that template?

But not having much luck figuring out how to do that?  

I have URIs saving with my elements but how do I note which template to load?

I assume it has something to do with registering routes but I'm not exactly sure where to start?
You'll need to override the BaseElementType's routeRequestForMatchedElement method in your element type class as follows:

public function routeRequestForMatchedElement(BaseElementModel $element)
{
    return array(
        'action' =&gt; 'templates/render',
        'params' =&gt; array(
            'template' =&gt; '_page',
            'variables' =&gt; array(
                'page' =&gt; $element
            )
        )
    );
}