Creating a container

Hi, ive been looking through the documentation and cheatsheets but i can’t find a way to programmatically add containers…anyone got any idea how, i was thinking something like the following should be possible:

$pTemplate = PageTemplate::getByHandle(‘three_column’);
if(!$pTemplate) {
PageTemplate::add(‘three_column’, t(‘Three Column’), ‘three_column.png’, $pkg = null);

There are 2 files in the code I can find where a new container is created, doesn’t look quite as simple as some other things.

If you have a package it might be easier to just do it using the CIF stuff like they do in the Atomik (around line 447)


Thx hutman, that really helps!