Blog Sections Open

Preselecting the Resource Template on New Document Creation in Evolution CMS

How to open the new document form with a predefined template already selected.

When editors create many documents under the same parent, selecting the template manually every time becomes unnecessary friction. A simple way to speed that up is to prefill the template on the new document form.

The original plugin solution used OnDocFormPrerender and read the desired template from the request:

global $content;
if (isset($_GET['template']) && $_GET['template'] != '') {
    $content['template'] = $_GET['template'];
}
return $content;

That makes URLs like this useful for editor shortcuts:

index.php?a=4&pid=14&template=5

In practice, this is a neat workflow improvement for content-heavy sections, imported structures, or custom manager buttons. The editor lands on the right parent and the correct template is already chosen.

The pattern is simple, but it fits Evolution CMS well: when the manager does not give you the exact editorial shortcut you need, a small event-driven customization often closes the gap cleanly.

Newer post

Showing TV-Based Images in AjaxSearch Results with phpThumb

How to render TV-based images in AjaxSearch result templates and when phpThumb processing needs extra care.

Older post

Filtering Ditto Listings with AJAX Category Selection in Evolution CMS

How to reload Ditto results through AJAX when the visitor changes a category selector, and what to watch for with pagination.