public function _createContent(&$toReturn)
 {
     //Création du sous template.
     $tpl = new CopixTpl();
     CopixClassesFactory::fileInclude('cms|ServicesCMSPage');
     CopixContext::push('cms');
     $sHeadings = CopixClassesFactory::getInstanceOf('copixheadings|CopixHeadingsServices');
     $headings = $sHeadings->getTree();
     $cmsPages = new ServicesCMSPage();
     $pages = $cmsPages->getList();
     if (isset($this->_params['onlyLastVersion']) && $this->_params['onlyLastVersion'] == 1) {
         $pages = $this->_filterLastVersion($pages);
     }
     CopixContext::pop();
     //pagination
     foreach ($pages as $page) {
         $arPages[$page->id_head][] = $page;
     }
     $tpl->assign('arPublished', $arPages);
     $tpl->assign('arHeadings', $headings);
     $tpl->assign('select', $this->getParam('select'));
     $tpl->assign('back', $this->getParam('back'));
     $tpl->assign('popup', $this->getParam('popup'));
     $tpl->assign('height', Copixconfig::get('htmleditor|height'));
     $tpl->assign('width', Copixconfig::get('htmleditor|width'));
     //$tpl->assign ('editorType' , CopixConfig::get('htmleditor|type'));
     $tpl->assign('editorName', $this->getParam('editorName'));
     $toReturn = $tpl->fetch('page.select.ptpl');
     return true;
 }
 function _createContent(&$toReturn)
 {
     $tpl =& new CopixTpl();
     //page de présentation
     $homePageUrl = CopixConfig::get('|homePage');
     // special CopixCms : à retirer plus tard
     $foundPage = preg_match('/.*module=cms&action=get&id=(\\d*).*/', $homePageUrl, $matches);
     if ($foundPage) {
         require_once COPIX_MODULE_PATH . 'cms/' . COPIX_CLASSES_DIR . 'cmspage.services.class.php';
         Copixcontext::push('cms');
         $homePage = ServicesCMSPage::getOnline($matches[1]);
         Copixcontext::pop();
         if (isset($homePage->title_cmsp)) {
             $homePageUrl = $homePage->title_cmsp;
         }
     }
     // special CopixCms
     $tpl->assign('homePage', $homePageUrl);
     $toReturn = $tpl->fetch('admin.tpl');
     return true;
 }