panels[] = array( 'id' => 'frontpage-panel', 'title' => __( 'Front Page', 'trifold' ), 'description' => __( 'This frontpage containing section Introduction, About, Team, Services, Contact', 'trifold' ), 'priority' => '30', 'active_callback' => 'is_front_page' ); $this->sections[] = array( 'id' => 'intro-section', 'title' => __( 'Section Introduction', 'trifold' ), 'priority' => '5', 'panel' => 'frontpage-panel' ); $this->sections[] = array( 'id' => 'about-section', 'title' => __( 'Section About', 'trifold' ), 'priority' => '10', 'panel' => 'frontpage-panel' ); $this->sections[] = array( 'id' => 'team-section', 'title' => __( 'Section Team', 'trifold' ), 'priority' => '15', 'panel' => 'frontpage-panel' ); $this->sections[] = array( 'id' => 'services-section', 'title' => __( 'Section Services', 'trifold' ), 'priority' => '20', 'panel' => 'frontpage-panel' ); // General Section $this->sections[] = array( 'id' => 'general-section', 'title' => __( 'General', 'trifold' ), 'priority' => '30' ); // Header Section $this->sections[] = array( 'id' => 'header-section', 'title' => __( 'Header', 'trifold' ), 'priority' => '40' ); // Typography Section $this->sections[] = array( 'id' => 'typography-section', 'title' => __( 'Typography', 'trifold' ), 'priority' => '50' ); // Footer Section $this->sections[] = array( 'id' => 'footer-section', 'title' => __( 'Footer', 'trifold' ), 'priority' => '60' ); // Adds the sections to the $this->options array $this->options['sections'] = $this->sections; // Adds the panels to the $this->options array $this->options['panels'] = $this->panels; return $this->options; } /** * Register controls * * @return Array */ private function register_options() { $options = $this->options; // this control options require from customizer/options/*.php $require_settings = array( '/options/settings-frontpage.php', '/options/settings-general.php', '/options/settings-header.php', '/options/settings-typography.php', '/options/settings-footer.php', ); foreach ( $require_settings as $settings ) { require apply_filters( 'trifold_register_options', $this->customizer_path . $settings ); } // To delete custom mods use: customizer_library_remove_theme_mods(); return $options; } public function generate_options() { return array_merge( $this->register_panels(), $this->register_options() ); } } endif;