2023-06-30 21:21:48 +00:00
|
|
|
<?php
|
|
|
|
/**
|
2023-07-10 15:20:37 +00:00
|
|
|
* Curriculum functions and definitions
|
2023-06-30 21:21:48 +00:00
|
|
|
*
|
|
|
|
* @link https://developer.wordpress.org/themes/basics/theme-functions/
|
|
|
|
*
|
2023-07-10 15:20:37 +00:00
|
|
|
* @package Curriculum
|
|
|
|
* @since Curriculum 1.0
|
2023-06-30 21:21:48 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
|
2023-07-10 15:20:37 +00:00
|
|
|
if ( ! function_exists( 'curriculum_support' ) ) :
|
2023-06-30 21:21:48 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Sets up theme defaults and registers support for various WordPress features.
|
|
|
|
*
|
2023-07-10 15:20:37 +00:00
|
|
|
* @since Curriculum 1.0
|
2023-06-30 21:21:48 +00:00
|
|
|
*
|
|
|
|
* @return void
|
|
|
|
*/
|
2023-07-10 15:20:37 +00:00
|
|
|
function curriculum_support() {
|
2023-06-30 21:21:48 +00:00
|
|
|
|
|
|
|
// Enqueue editor styles.
|
|
|
|
add_editor_style( 'style.css' );
|
|
|
|
|
|
|
|
// Make theme available for translation.
|
2023-07-10 15:20:37 +00:00
|
|
|
load_theme_textdomain( 'curriculum' );
|
2023-06-30 21:21:48 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
endif;
|
|
|
|
|
2023-07-10 15:20:37 +00:00
|
|
|
add_action( 'after_setup_theme', 'curriculum_support' );
|
2023-06-30 21:21:48 +00:00
|
|
|
|
2023-07-10 15:20:37 +00:00
|
|
|
if ( ! function_exists( 'curriculum_styles' ) ) :
|
2023-06-30 21:21:48 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Enqueue styles.
|
|
|
|
*
|
2023-07-10 15:20:37 +00:00
|
|
|
* @since Curriculum 1.0
|
2023-06-30 21:21:48 +00:00
|
|
|
*
|
|
|
|
* @return void
|
|
|
|
*/
|
2023-07-10 15:20:37 +00:00
|
|
|
function curriculum_styles() {
|
2023-06-30 21:21:48 +00:00
|
|
|
|
|
|
|
// Register theme stylesheet.
|
|
|
|
wp_register_style(
|
2023-07-10 15:20:37 +00:00
|
|
|
'curriculum-style',
|
2023-06-30 21:21:48 +00:00
|
|
|
get_stylesheet_directory_uri() . '/style.css',
|
|
|
|
array(),
|
|
|
|
wp_get_theme()->get( 'Version' )
|
|
|
|
);
|
|
|
|
|
|
|
|
// Enqueue theme stylesheet.
|
2023-07-10 15:20:37 +00:00
|
|
|
wp_enqueue_style( 'curriculum-style' );
|
2023-06-30 21:21:48 +00:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
endif;
|
|
|
|
|
2023-07-10 15:20:37 +00:00
|
|
|
add_action( 'wp_enqueue_scripts', 'curriculum_styles' );
|