APF_Demo_PageMetaBox::replyToLoadPage PHP Метод

replyToLoadPage() публичный Метод

Called when the page starts loading.
public replyToLoadPage ( $oFactory ) : void
Результат void
    public function replyToLoadPage($oFactory)
    {
        // Set up the page settings
        $oFactory->setPageHeadingTabsVisibility(false);
        // disables the page heading tabs by passing false.
        $oFactory->setInPageTabTag('h2');
        // sets the tag used for in-page tabs
        // Enqueue styles
        $oFactory->enqueueStyle(AdminPageFrameworkLoader_Registry::$sDirPath . '/asset/css/code.css');
        // Tabs
        new APF_Demo_PageMetaBox__FirstTab($oFactory, $this->_sPageSlug);
        new APF_Demo_PageMetaBox__SecondTab($oFactory, $this->_sPageSlug);
        // Page meta boxes
        new APF_Demo_PageMetaBox__Normal(null, __('Normal', 'admin-page-framework-loader'), array($this->_sPageSlug => array('first')), 'normal', 'default');
        new APF_Demo_PageMetaBox__Advanced(null, __('Advanced', 'admin-page-framework-loader'), array($this->_sPageSlug => array('first')), 'advanced', 'default');
        new APF_Demo_PageMetaBox__Nested(null, __('Nested Sections', 'admin-page-framework-loader'), array($this->_sPageSlug => array('second')), 'normal', 'default');
        new APF_Demo_PageMetaBox__Side(null, __('Side', 'admin-page-framework-loader'), array($this->_sPageSlug => array('first', 'second')), 'side', 'default');
        new APF_Demo_PageMetaBox__WithFormSection(null, __('With a Form Section', 'admin-page-framework-loader'), array($this->_sPageSlug => array('first', 'second')), 'side', 'low');
        new APF_Demo_PageMetaBox__NoField(null, __('Information Box', 'admin-page-framework-loader'), array($this->_sPageSlug => array('first', 'second')), 'side', 'low');
        // Pointer Tool Tips
        new AdminPageFramework_PointerToolTip(array($this->_sPageSlug), 'apf_demo_page_meta_boxes', array('target' => '#apf_metabox_for_pages_normal', 'options' => array('content' => sprintf('<h3> %1$s </h3> <p> %2$s </p>', __('Page Meta Boxes', 'admin-page-framework-loader'), __('Demonstrates the use of meta boxes for admin pages.', 'admin-page-framework-loader') . ' ' . __('Usually meta boxes are displayed in post editing pages but with Admin Page Framework, you can display them in generic admin pages you create with the framework.', 'admin-page-framework-loader')), 'position' => array('edge' => 'top', 'align' => 'middle'))));
    }