public function getSections($pageName)
{
$context = $this->context->get();
$langid = $context->getLocale()->getLanguageId();
$tmplPaths = $this->aimeos->get()->getCustomPaths('client/html/templates');
$view = $this->view->create($context, $tmplPaths, $langid);
$context->setView($view);
$pagesConfig = $this->config->get('shop.page', array());
$result = array('aibody' => array(), 'aiheader' => array());
if (isset($pagesConfig[$pageName])) {
foreach ((array) $pagesConfig[$pageName] as $clientName) {
$client = \Aimeos\Client\Html\Factory::createClient($context, $tmplPaths, $clientName);
$client->setView(clone $view);
$client->process();
$result['aibody'][$clientName] = $client->getBody();
$result['aiheader'][$clientName] = $client->getHeader();
}
}
return $result;
}