'page', 'posts_per_page' => 1, 'title' => $bookstore_exhibition_pagename ); $bookstore_exhibition_query = new WP_Query( $bookstore_exhibition_args ); $bookstore_exhibition_page_id = '1'; if (isset($bookstore_exhibition_query->post->ID)) { $bookstore_exhibition_page_id = $bookstore_exhibition_query->post->ID; } return $bookstore_exhibition_page_id; } //about theme info add_action( 'admin_menu', 'bookstore_exhibition_gettingstarted' ); function bookstore_exhibition_gettingstarted() { add_theme_page( esc_html__('Bookstore Exhibition', 'bookstore-exhibition'), esc_html__('Bookstore Exhibition', 'bookstore-exhibition'), 'edit_theme_options', 'bookstore_exhibition_about', 'bookstore_exhibition_mostrar_guide'); } // Add a Custom CSS file to WP Admin Area function bookstore_exhibition_admin_theme_style() { wp_enqueue_style('bookstore-exhibition-custom-admin-style', esc_url(get_template_directory_uri()) . '/inc/getstart/getstart.css'); wp_enqueue_script('bookstore-exhibition-tabs', esc_url(get_template_directory_uri()) . '/inc/getstart/js/tab.js'); wp_enqueue_style( 'font-awesome-css', get_template_directory_uri().'/assets/css/fontawesome-all.css' ); // Admin notice code START wp_register_script('bookstore-exhibition-notice', esc_url(get_template_directory_uri()) . '/inc/getstart/js/notice.js', array('jquery'), time(), true); wp_enqueue_script('bookstore-exhibition-notice'); // Admin notice code END } add_action('admin_enqueue_scripts', 'bookstore_exhibition_admin_theme_style'); // Changelog if ( ! defined( 'BOOKSTORE_EXHIBITION_CHANGELOG_URL' ) ) { define( 'BOOKSTORE_EXHIBITION_CHANGELOG_URL', get_template_directory() . '/readme.txt' ); } function bookstore_exhibition_changelog_screen() { global $wp_filesystem; $bookstore_exhibition_changelog_file = apply_filters( 'bookstore_exhibition_changelog_file', BOOKSTORE_EXHIBITION_CHANGELOG_URL ); if ( $bookstore_exhibition_changelog_file && is_readable( $bookstore_exhibition_changelog_file ) ) { WP_Filesystem(); $bookstore_exhibition_changelog = $wp_filesystem->get_contents( $bookstore_exhibition_changelog_file ); $bookstore_exhibition_changelog_list = bookstore_exhibition_parse_changelog( $bookstore_exhibition_changelog ); echo '