TemplateHandler = $templateHandler; $this->domain = $domain; $this->slug = $slug; $this->title = $title; $this->class = $class; $this->position = $position; add_filter( 'f12_cf7_doubleoptin_settings', array( $this, 'getSettings' ) ); } public function hideInMenu() { return false; } public function getPosition() { return $this->position; } public function isDashboard() { return $this->getPosition() == 0; } public function getDomain() { return $this->domain; } public function getSlug() { return $this->slug; } public function getTitle() { return $this->title; } public function getClass() { return $this->class; } /** * @param $settings * * @return mixed */ public abstract function getSettings( $settings ); /** * @param string $slug - The WordPress Slug * @param string $page - The Name of the current Page e.g.: license * * @return void */ protected abstract function theSidebar( $slug, $page ); /** * @param string $slug - The WordPress Slug * @param string $page - The Name of the current Page e.g.: license * * @return void */ protected abstract function theContent( $slug, $page, $settings ); /** * @return void * @private WordPress HOOK */ public function renderContent( $slug, $page ) { if ( $this->slug != $page ) { return; } $settings = CF7DoubleOptIn::getInstance()->getSettings(); echo esc_html( Messages::getInstance()->getAll() ); do_action( 'f12_cf7_doubleoptin_ui_' . $page . '_before_box' ); ?>
theContent( $slug, $page, $settings ); do_action( 'f12_cf7_doubleoptin_ui_' . $page . '_after_content', $settings ); ?>
slug != $page ) { return; } $this->theSidebar( $slug, $page ); } } }