/** * Alone functions and definitions * * @link https://developer.wordpress.org/themes/basics/theme-functions/ * * @package WordPress * @subpackage Alone * @since Alone 7.0 */ /** * Alone only works in WordPress 4.7 or later. */ update_option( '_verifytheme_settings', [ 'purchase_code' => 'purchase_code' ] ); if ( version_compare( $GLOBALS['wp_version'], '4.7', '<' ) ) { require get_template_directory() . '/inc/back-compat.php'; return; } if ( ! function_exists( 'alone_setup' ) ) : /** * Sets up theme defaults and registers support for various WordPress features. * * Note that this function is hooked into the after_setup_theme hook, which * runs before the init hook. The init hook is too late for some features, such * as indicating support for post thumbnails. */ function alone_setup() { /* * Make theme available for translation. * Translations can be filed in the /languages/ directory. * If you're building a theme based on Alone, use a find and replace * to change 'alone' to the name of your theme in all the template files. */ load_theme_textdomain( 'alone', get_template_directory() . '/languages' ); // Add default posts and comments RSS feed links to head. add_theme_support( 'automatic-feed-links' ); /* * Let WordPress manage the document title. * By adding theme support, we declare that this theme does not use a * hard-coded tag in the document head, and expect WordPress to * provide it for us. */ add_theme_support( 'title-tag' ); /* * Enable support for Post Thumbnails on posts and pages. * * @link https://developer.wordpress.org/themes/functionality/featured-images-post-thumbnails/ */ add_theme_support( 'post-thumbnails' ); set_post_thumbnail_size( 1568, 9999 ); // This theme uses wp_nav_menu() in two locations. register_nav_menus( array( 'primary' => __( 'Primary Menu', 'alone' ), 'footer' => __( 'Footer Menu', 'alone' ), ) ); /* * Switch default core markup for search form, comment form, and comments * to output valid HTML5. */ add_theme_support( 'html5', array( 'search-form', 'comment-form', 'comment-list', 'gallery', 'caption', 'script', 'style', ) ); /** * Add support for core custom logo. * * @link https://codex.wordpress.org/Theme_Logo */ add_theme_support( 'custom-logo', array( 'height' => 74, 'width' => 165, 'flex-width' => true, 'flex-height' => true, ) ); // Add theme support for selective refresh for widgets. add_theme_support( 'customize-selective-refresh-widgets' ); // Add support for Block Styles. add_theme_support( 'wp-block-styles' ); // Add support for full and wide align images. add_theme_support( 'align-wide' ); // Add support for editor styles. add_theme_support( 'editor-styles' ); // Enqueue editor styles. add_editor_style( 'style-editor.css' ); // Add custom editor font sizes. add_theme_support( 'editor-font-sizes', array( array( 'name' => __( 'Small', 'alone' ), 'shortName' => __( 'S', 'alone' ), 'size' => 19.5, 'slug' => 'small', ), array( 'name' => __( 'Normal', 'alone' ), 'shortName' => __( 'M', 'alone' ), 'size' => 22, 'slug' => 'normal', ), array( 'name' => __( 'Large', 'alone' ), 'shortName' => __( 'L', 'alone' ), 'size' => 36.5, 'slug' => 'large', ), array( 'name' => __( 'Huge', 'alone' ), 'shortName' => __( 'XL', 'alone' ), 'size' => 49.5, 'slug' => 'huge', ), ) ); // Editor color palette. add_theme_support( 'editor-color-palette', array( array( 'name' => 'default' === alone_get_option('custom_colors') ? __( 'Blue', 'alone' ) : null, 'slug' => 'primary', 'color' => alone_get_main_color(), ), array( 'name' => __( 'Dark Gray', 'alone' ), 'slug' => 'dark-gray', 'color' => '#111', ), array( 'name' => __( 'Light Gray', 'alone' ), 'slug' => 'light-gray', 'color' => '#333', ), array( 'name' => __( 'White', 'alone' ), 'slug' => 'white', 'color' => '#FFF', ), ) ); // Add support for responsive embedded content. add_theme_support( 'responsive-embeds' ); } endif; add_action( 'after_setup_theme', 'alone_setup' ); /** * Register widget area. * * @link https://developer.wordpress.org/themes/functionality/sidebars/#registering-a-sidebar */ function alone_widgets_init() { register_sidebar( array( 'name' => __( 'Blog', 'alone' ), 'id' => 'blog-sidebar', 'description' => __( 'Add widgets here to appear in your blog.', 'alone' ), 'before_widget' => '<section id="%1$s" class="widget %2$s">', 'after_widget' => '</section>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); register_sidebar( array( 'name' => __( 'Topbar', 'alone' ), 'id' => 'topbar-sidebar', 'description' => __( 'Add widgets here to appear in your header.', 'alone' ), 'before_widget' => '<section id="%1$s" class="widget %2$s">', 'after_widget' => '</section>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ) ); register_sidebar( array( 'name' => __( 'Footer', 'alone' ), 'id' => 'footer-sidebar', 'description' => __( 'Add widgets here to appear in your footer.', 'alone' ), 'before_widget' => '<section id="%1$s" class="widget %2$s">', 'after_widget' => '</section>', <!DOCTYPE html> <html lang="en-US"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" /> <title> Events from May 23, 2022 – January 30, 2024 – Kenya Association of Paediatric Surgeons

2