/**
  * Add new section to customizer interface
  *
  * @param \SilverWp\Customizer\Section\SectionInterface $section
  *
  * @access public
  * @return $this
  */
 public function addSection($section)
 {
     if ($section instanceof SectionInterface) {
         $this->sections[$section->getName()] = $section;
     } elseif ($section instanceof PanelInterface) {
         $this->sections[$section->getPanelId()] = $section;
     }
     return $this;
 }
Beispiel #2
0
 /**
  *
  * Add section to panel container
  *
  * @param \SilverWp\Customizer\Section\SectionInterface $section
  *
  * @access public
  */
 public function addSection(SectionInterface $section)
 {
     $section->setPanelId($this->getPanelId());
     $this->sections[] = $section;
 }