framework/RedKiteCms/Content/Theme/ThemeSlotsGenerator.php
public function synchronize(Page $page, array $pages)
    {
        if (!$this->configurationHandler->isTheme()) {
            return;
        }

        foreach ($pages as $pageValues) {
            $tokens = explode("_", $pageValues["seo"][0]["language"]);
            $pageOptions = array(
                'page' => $pageValues["name"],
                'language' => $tokens[0],
                'country' => $tokens[1],
            );
            $page->render($this->configurationHandler->siteDir(), $pageOptions);
            $this->saveTemplateSlots($page->getPageSlots(), $pageValues["template"]);
        }

        $this->saveTemplateSlots($page->getCommonSlots(), 'base');
    }
public function synchronize(Page $page, array $pages)
    {
        if (!$this->configurationHandler->isTheme()) {
            return;
        }

        foreach ($pages as $pageValues) {
            $tokens = explode("_", $pageValues["seo"][0]["language"]);
            $pageOptions = array(
                'page' => $pageValues["name"],
                'language' => $tokens[0],
                'country' => $tokens[1],
            );
            $page->render($this->configurationHandler->siteDir(), $pageOptions);
            $this->saveTemplateSlots($page->getPageSlots(), $pageValues["template"]);
        }

        $this->saveTemplateSlots($page->getCommonSlots(), 'base');
    }
public function synchronize ( Page $ page , array $ pages ) { if ( ! $ this -> configurationHandler -> isTheme ( ) ) { return ; } foreach ( $ pages as $ pageValues ) { $ tokens = explode ( "_" , $ pageValues [ "seo" ] [ 0 ] [ "language" ] ) ; $ pageOptions = array ( 'page' => $ pageValues [ "name" ] , 'language' => $ tokens [ 0 ] , 'country' => $ tokens [ 1 ] , ) ; $ page -> render ( $ this -> configurationHandler -> siteDir ( ) , $ pageOptions ) ; $ this -> saveTemplateSlots ( $ page -> getPageSlots ( ) , $ pageValues [ "template" ] ) ; } $ this -> saveTemplateSlots ( $ page -> getCommonSlots ( ) , 'base' ) ; }
Synchronizes the site slots with the theme slots

@param \RedKiteCms\FilesystemEntity\Page $page
@param array $pages
Synchronizes the site slots with the theme slots