code: public function insert($name, array $data=null)
  	{
  		/** @var Template $tpl */
  		if ($this instanceof Template)
  		{
  			$tpl = new static($name);
  		}
  		elseif (TL_MODE == 'BE')
  		{
  			$tpl = new BackendTemplate($name);
  		}
  		else
  		{
  			$tpl = new FrontendTemplate($name);
  		}
  
  		if ($data !== null)
  		{
  			$tpl->setData($data);
  		}
  
  		echo $tpl->parse();
  	}
docs: Insert a template
  
  @param string $name The template name
  @param array  $data An optional data array