esc_html__( 'Coming Soon', 'powerkit' ), 'post_content' => powerkit_coming_soon_default_content(), 'post_type' => 'page', 'post_status' => 'publish', 'post_author' => 1, ) ) ); update_option( 'powerkit_coming_soon_init', true ); update_option( 'powerkit_coming_soon_page', $page_id ); } } /** * Prints admin screen notices. */ public function notices() { $screen = get_current_screen(); if ( false !== strpos( $screen->base, $this->slug ) ) { return; } // Check Status. if ( ! powerkit_coming_soon_status() ) { return; } // Check Notice. if ( 'yes' === get_option( 'powerkit_coming_soon_notice', 'yes' ) ) { ?>

deactivate as soon as you are done.', 'powerkit' ), powerkit_get_page_url( $this->slug ) ), 'post' ); ?>

ID === (int) $page_id ) { $states[] = esc_html__( 'Coming Soon Page', 'powerkit' ); } return $states; } /** * Register admin page * * @since 1.0.0 */ public function register_options_page() { add_options_page( esc_html__( 'Coming Soon', 'powerkit' ), esc_html__( 'Coming Soon', 'powerkit' ), 'manage_options', powerkit_get_page_slug( $this->slug ), array( $this, 'build_options_page' ) ); } /** * Build admin page * * @since 1.0.0 */ public function build_options_page() { if ( ! current_user_can( 'manage_options' ) ) { wp_die( esc_html__( 'You do not have sufficient rights to view this page.', 'powerkit' ) ); } $this->save_options_page(); ?>

query( array( 'posts_per_page' => -1, 'post_type' => 'page', ) ); if ( $pages ) { ?>

%s

', esc_html__( 'Settings saved.', 'powerkit' ) ); } } }