display( 'Name' ), esc_html__( 'About', 'marinate' ) . ' ' . $theme->display( 'Name' ), 'activate_plugins', 'marinate-welcome', array( $this, 'welcome_screen' ) ); add_action( 'admin_print_styles-' . $page, array( $this, 'enqueue_styles' ) ); } /** * Enqueue styles. */ public function enqueue_styles() { $marinate_theme = wp_get_theme(); $marinate_version = $marinate_theme->get( 'Version' ); wp_enqueue_style( 'marinate-welcome', get_template_directory_uri() . '/inc/admin/css/admin-welcome.css', array(), $marinate_version ); } /** * Add admin notice. */ public function admin_notice() { global $marinate_version, $pagenow; wp_enqueue_style( 'marinate-message', get_template_directory_uri() . '/inc/admin/css/admin-welcome.css', array(), $marinate_version ); // Let's bail on theme activation. if ( 'themes.php' == $pagenow && isset( $_GET['activated'] ) ) { add_action( 'admin_notices', array( $this, 'welcome_notice' ) ); update_option( 'Marinate_Admin_notice_welcome', 1 ); // No option? Let run the notice wizard again.. } elseif( ! get_option( 'Marinate_Admin_notice_welcome' ) ) { add_action( 'admin_notices', array( $this, 'welcome_notice' ) ); } } /** * Hide a notice if the GET variable is set. */ public static function hide_notices() { if ( isset( $_GET['marinate-hide-notice'] ) && isset( $_GET['marinate_notice_nonce'] ) ) { if ( ! wp_verify_nonce( $_GET['marinate_notice_nonce'], 'marinate_hide_notices_nonce' ) ) { wp_die( esc_html( 'Action failed. Please refresh the page and retry.', 'marinate' ) ); } if ( ! current_user_can( 'manage_options' ) ) { wp_die( esc_html( 'Cheatin’ huh?', 'marinate' ) ); } $hide_notice = sanitize_text_field( $_GET['marinate-hide-notice'] ); update_option( 'Marinate_Admin_notice_welcome', 1 ); } } /** * Show welcome notice. */ public function welcome_notice() { ?>

', '' ); ?>

display( 'Name' )); ?>

display( 'Description' )); ?>

{ $current_tab . '_screen' }(); } // Fallback to about screen. return $this->about_screen(); } /** * Output the about screen. */ public function about_screen() { $theme = wp_get_theme( get_template() ); ?>
intro(); ?>

display( 'Name' )); ?>

display( 'Name' )); ?>

|
intro(); ?>

get_contents( $changelog_file ); $changelog_list = $this->parse_changelog( $changelog ); echo wp_kses_post( $changelog_list ); } ?>
'; foreach ( $changes as $index => $line ) { $changelog .= wp_kses_post( preg_replace( '~(=\s*Version\s*(\d+(?:\.\d+)+)\s*=|$)~Uis', '${1}', $line ) ); } $changelog .= ''; } return wp_kses_post( $changelog ); } /** * Output the free vs pro screen. */ public function free_vs_pro_screen() { ?>
intro(); ?>

intro(); ?>
'metricthemes', ); // Set the $request array. $request = array( 'body' => array( 'action' => 'query_themes', 'request' => serialize( (object)$args ) ) ); $themes = $this->metricthemes_get_themes( $request ); $active_theme = wp_get_theme()->get( 'Name' ); $counter = 1; // For currently active theme. foreach ( $themes->themes as $theme ) { if( $active_theme == $theme->name ) { ?>

: name); ?>

themes as $theme ) { if( $active_theme != $theme->name ) { // Set the argument array with author name. $args = array( 'slug' => $theme->slug, ); // Set the $request array. $request = array( 'body' => array( 'action' => 'theme_information', 'request' => serialize( (object)$args ) ) ); $theme_details = $this->metricthemes_get_themes( $request ); ?>

name); ?>

slug )->exists() ) { ?> 'install-theme', 'theme' => $theme->slug, ), self_admin_url( 'update.php' ) ); ?>