public function addPages($pages, $rootPage = null, $fromSiteMap = false, $language = null)
    {
        // Save the pages.
        $this->foundPages = $pages;
        unset($pages);

        // Run each entry in the published config array.
        foreach ($this->getConfigs() as $config) {
            if (!$config['published']) {
                continue;
            }
            $this->getMetaModelsPages(
                $config,
                $rootPage,
                $language
            );
        }

        asort($this->foundPages);

        // Return the new list.
        return $this->foundPages;
    }
public function addPages($pages, $rootPage = null, $fromSiteMap = false, $language = null)
    {
        // Save the pages.
        $this->foundPages = $pages;
        unset($pages);

        // Run each entry in the published config array.
        foreach ($this->getConfigs() as $config) {
            if (!$config['published']) {
                continue;
            }
            $this->getMetaModelsPages(
                $config,
                $rootPage,
                $language
            );
        }

        asort($this->foundPages);

        // Return the new list.
        return $this->foundPages;
    }
public function addPages ( $ pages , $ rootPage = null , $ fromSiteMap = false , $ language = null ) { // Save the pages. $ this -> foundPages = $ pages ; unset ( $ pages ) ; // Run each entry in the published config array. foreach ( $ this -> getConfigs ( ) as $ config ) { if ( ! $ config [ 'published' ] ) { continue ; } $ this -> getMetaModelsPages ( $ config , $ rootPage , $ language ) ; } asort ( $ this -> foundPages ) ; // Return the new list. return $ this -> foundPages ; }
Start point for the hook getSearchablePages.

@param array       $pages       List with all pages.

@param int|null    $rootPage    ID of the root page.

@param bool|null   $fromSiteMap True when called from sitemap generator, null otherwise.

@param string|null $language    The current language.

@return array

@throws \Doctrine\DBAL\DBALException When an database error occur.

@see \RebuildIndex::run()
@see \Automator::generateSitemap()

@SuppressWarnings(PHPMD.UnusedFormalParameter)
Start point for the hook getSearchablePages .