diff --git a/footer.php b/footer.php index 131a3dc..5cfb740 100644 --- a/footer.php +++ b/footer.php @@ -87,7 +87,7 @@
- +
diff --git a/functions.php b/functions.php index 19ca85e..57ba372 100644 --- a/functions.php +++ b/functions.php @@ -11,9 +11,9 @@ * Load theme files /* ------------------------------------------------------------------------- */ -if ( ! function_exists( 'alx_load' ) ) { +if ( ! function_exists( 'typecore_load' ) ) { - function alx_load() { + function typecore_load() { // Load theme languages load_theme_textdomain( 'typecore', get_template_directory().'/languages' ); @@ -34,7 +34,7 @@ function alx_load() { } } -add_action( 'after_setup_theme', 'alx_load' ); +add_action( 'after_setup_theme', 'typecore_load' ); /* ------------------------------------------------------------------------- * @@ -47,9 +47,9 @@ function alx_load() { /* Theme setup /* ------------------------------------ */ -if ( ! function_exists( 'alx_setup' ) ) { +if ( ! function_exists( 'typecore_setup' ) ) { - function alx_setup() { + function typecore_setup() { // Enable title tag add_theme_support( 'title-tag' ); @@ -81,26 +81,26 @@ function alx_setup() { } } -add_action( 'after_setup_theme', 'alx_setup' ); +add_action( 'after_setup_theme', 'typecore_setup' ); /* Deregister /* ------------------------------------ */ -if ( ! function_exists( 'alx_deregister' ) ) { +if ( ! function_exists( 'typecore_deregister' ) ) { - function alx_deregister() { + function typecore_deregister() { wp_deregister_style( 'wp-pagenavi' ); } } -add_action( 'wp_print_styles', 'alx_deregister', 100 ); +add_action( 'wp_print_styles', 'typecore_deregister', 100 ); /* Register sidebars /* ------------------------------------ */ -if ( ! function_exists( 'alx_sidebars' ) ) { +if ( ! function_exists( 'typecore_sidebars' ) ) { - function alx_sidebars() { + function typecore_sidebars() { register_sidebar(array( 'name' => 'Primary','id' => 'primary','description' => "Normal full width sidebar", 'before_widget' => '
','after_widget' => '
','before_title' => '

','after_title' => '

')); register_sidebar(array( 'name' => 'Secondary','id' => 'secondary','description' => "Normal full width sidebar", 'before_widget' => '
','after_widget' => '
','before_title' => '

','after_title' => '

')); @@ -119,14 +119,14 @@ function alx_sidebars() { } } -add_action( 'widgets_init', 'alx_sidebars' ); +add_action( 'widgets_init', 'typecore_sidebars' ); /* Enqueue javascript /* ------------------------------------ */ -if ( ! function_exists( 'alx_scripts' ) ) { +if ( ! function_exists( 'typecore_scripts' ) ) { - function alx_scripts() { + function typecore_scripts() { wp_enqueue_script( 'typecore-flexslider', get_template_directory_uri() . '/js/jquery.flexslider.min.js', array( 'jquery' ),'', false ); wp_enqueue_script( 'typecore-fitvids', get_template_directory_uri() . '/js/jquery.fitvids.js', array( 'jquery' ),'', true ); wp_enqueue_script( 'typecore-scripts', get_template_directory_uri() . '/js/scripts.js', array( 'jquery' ),'', true ); @@ -134,14 +134,14 @@ function alx_scripts() { } } -add_action( 'wp_enqueue_scripts', 'alx_scripts' ); +add_action( 'wp_enqueue_scripts', 'typecore_scripts' ); /* Enqueue css /* ------------------------------------ */ -if ( ! function_exists( 'alx_styles' ) ) { +if ( ! function_exists( 'typecore_styles' ) ) { - function alx_styles() { + function typecore_styles() { wp_enqueue_style( 'typecore-style', get_stylesheet_uri() ); if ( get_theme_mod('responsive','on') =='on' ) { wp_enqueue_style( 'typecore-responsive', get_template_directory_uri().'/responsive.css' ); } if ( get_theme_mod('custom','off') == 'on' ) { wp_enqueue_style( 'typecore-custom', get_template_directory_uri().'/custom.css' ); } @@ -149,14 +149,14 @@ function alx_styles() { } } -add_action( 'wp_enqueue_scripts', 'alx_styles' ); +add_action( 'wp_enqueue_scripts', 'typecore_styles' ); /* Register custom sidebars /* ------------------------------------ */ -if ( ! function_exists( 'alx_custom_sidebars' ) ) { +if ( ! function_exists( 'typecore_custom_sidebars' ) ) { - function alx_custom_sidebars() { + function typecore_custom_sidebars() { if ( !get_theme_mod('sidebar-areas') =='' ) { $sidebars = get_theme_mod('sidebar-areas', array()); @@ -172,7 +172,7 @@ function alx_custom_sidebars() { } } -add_action( 'widgets_init', 'alx_custom_sidebars' ); +add_action( 'widgets_init', 'typecore_custom_sidebars' ); /* ------------------------------------------------------------------------- * @@ -181,9 +181,9 @@ function alx_custom_sidebars() { /* Layout class /* ------------------------------------ */ -if ( ! function_exists( 'alx_layout_class' ) ) { +if ( ! function_exists( 'typecore_layout_class' ) ) { - function alx_layout_class() { + function typecore_layout_class() { // Default layout $layout = 'col-3cm'; $default = 'col-3cm'; @@ -223,9 +223,9 @@ function alx_layout_class() { /* Dynamic sidebar primary /* ------------------------------------ */ -if ( ! function_exists( 'alx_sidebar_primary' ) ) { +if ( ! function_exists( 'typecore_sidebar_primary' ) ) { - function alx_sidebar_primary() { + function typecore_sidebar_primary() { // Default sidebar $sidebar = 'primary'; @@ -257,9 +257,9 @@ function alx_sidebar_primary() { /* Dynamic sidebar secondary /* ------------------------------------ */ -if ( ! function_exists( 'alx_sidebar_secondary' ) ) { +if ( ! function_exists( 'typecore_sidebar_secondary' ) ) { - function alx_sidebar_secondary() { + function typecore_sidebar_secondary() { // Default sidebar $sidebar = 'secondary'; @@ -291,9 +291,9 @@ function alx_sidebar_secondary() { /* Social links /* ------------------------------------ */ -if ( ! function_exists( 'alx_social_links' ) ) { +if ( ! function_exists( 'typecore_social_links' ) ) { - function alx_social_links() { + function typecore_social_links() { if ( !get_theme_mod('social-links') =='' ) { $links = get_theme_mod('social-links', array()); if ( !empty( $links ) ) { @@ -327,9 +327,9 @@ function alx_social_links() { /* Site name/logo /* ------------------------------------ */ -if ( ! function_exists( 'alx_site_title' ) ) { +if ( ! function_exists( 'typecore_site_title' ) ) { - function alx_site_title() { + function typecore_site_title() { // Text or image? if ( get_theme_mod('custom-logo') ) { @@ -354,9 +354,9 @@ function alx_site_title() { /* Page title /* ------------------------------------ */ -if ( ! function_exists( 'alx_page_title' ) ) { +if ( ! function_exists( 'typecore_page_title' ) ) { - function alx_page_title() { + function typecore_page_title() { global $post; $heading = esc_attr( get_post_meta($post->ID,'_heading',true) ); @@ -374,9 +374,9 @@ function alx_page_title() { /* Blog title /* ------------------------------------ */ -if ( ! function_exists( 'alx_blog_title' ) ) { +if ( ! function_exists( 'typecore_blog_title' ) ) { - function alx_blog_title() { + function typecore_blog_title() { global $post; $heading = esc_attr( get_theme_mod('blog-heading') ); $subheading = esc_attr( get_theme_mod('blog-subheading') ); @@ -397,9 +397,9 @@ function alx_blog_title() { /* Related posts /* ------------------------------------ */ -if ( ! function_exists( 'alx_related_posts' ) ) { +if ( ! function_exists( 'typecore_related_posts' ) ) { - function alx_related_posts() { + function typecore_related_posts() { wp_reset_postdata(); global $post; @@ -448,9 +448,9 @@ function alx_related_posts() { /* Get images attached to post /* ------------------------------------ */ -if ( ! function_exists( 'alx_post_images' ) ) { +if ( ! function_exists( 'typecore_post_images' ) ) { - function alx_post_images( $args=array() ) { + function typecore_post_images( $args=array() ) { global $post; $defaults = array( @@ -472,9 +472,9 @@ function alx_post_images( $args=array() ) { /* Get featured post ids /* ------------------------------------ */ -if ( ! function_exists( 'alx_get_featured_post_ids' ) ) { +if ( ! function_exists( 'typecore_get_featured_post_ids' ) ) { - function alx_get_featured_post_ids() { + function typecore_get_featured_post_ids() { $args = array( 'category' => get_theme_mod('featured-category',''), 'numberposts' => get_theme_mod('featured-posts-count','3') @@ -495,9 +495,9 @@ function alx_get_featured_post_ids() { /* Post formats script /* ------------------------------------ */ -if ( ! function_exists( 'alx_post_formats_script' ) ) { +if ( ! function_exists( 'typecore_post_formats_script' ) ) { - function alx_post_formats_script( $hook ) { + function typecore_post_formats_script( $hook ) { // Only load on posts, pages if ( !in_array($hook, array('post.php','post-new.php')) ) return; @@ -505,7 +505,7 @@ function alx_post_formats_script( $hook ) { } } -add_action( 'admin_enqueue_scripts', 'alx_post_formats_script'); +add_action( 'admin_enqueue_scripts', 'typecore_post_formats_script'); /* ------------------------------------------------------------------------- * @@ -514,10 +514,10 @@ function alx_post_formats_script( $hook ) { /* Body class /* ------------------------------------ */ -if ( ! function_exists( 'alx_body_class' ) ) { +if ( ! function_exists( 'typecore_body_class' ) ) { - function alx_body_class( $classes ) { - $classes[] = alx_layout_class(); + function typecore_body_class( $classes ) { + $classes[] = typecore_layout_class(); if ( get_theme_mod( 'boxed','off' ) != 'on' ) { $classes[] = 'full-width'; } if ( get_theme_mod( 'boxed','off' ) == 'on' ) { $classes[] = 'boxed'; } if ( get_theme_mod( 'center','off' ) == 'on' ) { $classes[] = 'center'; } @@ -531,14 +531,14 @@ function alx_body_class( $classes ) { } } -add_filter( 'body_class', 'alx_body_class' ); +add_filter( 'body_class', 'typecore_body_class' ); /* Custom rss feed /* ------------------------------------ */ -if ( ! function_exists( 'alx_feed_link' ) ) { +if ( ! function_exists( 'typecore_feed_link' ) ) { - function alx_feed_link( $output, $feed ) { + function typecore_feed_link( $output, $feed ) { // Do not redirect comments feed if ( strpos( $output, 'comments' ) ) return $output; @@ -547,38 +547,38 @@ function alx_feed_link( $output, $feed ) { } } -add_filter( 'feed_link', 'alx_feed_link', 10, 2 ); +add_filter( 'feed_link', 'typecore_feed_link', 10, 2 ); /* Excerpt ending /* ------------------------------------ */ -if ( ! function_exists( 'alx_excerpt_more' ) ) { +if ( ! function_exists( 'typecore_excerpt_more' ) ) { - function alx_excerpt_more( $more ) { + function typecore_excerpt_more( $more ) { return '...'; } } -add_filter( 'excerpt_more', 'alx_excerpt_more' ); +add_filter( 'excerpt_more', 'typecore_excerpt_more' ); /* Excerpt length /* ------------------------------------ */ -if ( ! function_exists( 'alx_excerpt_length' ) ) { +if ( ! function_exists( 'typecore_excerpt_length' ) ) { - function alx_excerpt_length( $length ) { + function typecore_excerpt_length( $length ) { return get_theme_mod('excerpt-length','24',$length); } } -add_filter( 'excerpt_length', 'alx_excerpt_length', 999 ); +add_filter( 'excerpt_length', 'typecore_excerpt_length', 999 ); /* Add responsive container to embeds /* ------------------------------------ */ -if ( ! function_exists( 'alx_embed_html' ) ) { +if ( ! function_exists( 'typecore_embed_html' ) ) { - function alx_embed_html( $html, $url ) { + function typecore_embed_html( $html, $url ) { $pattern = '/^https?:\/\/(www\.)?twitter\.com/'; $is_twitter = preg_match( $pattern, $url ); @@ -591,26 +591,26 @@ function alx_embed_html( $html, $url ) { } } -add_filter( 'embed_oembed_html', 'alx_embed_html', 10, 3 ); +add_filter( 'embed_oembed_html', 'typecore_embed_html', 10, 3 ); /* Add responsive container to jetpack embeds /* ------------------------------------ */ -if ( ! function_exists( 'alx_embed_html_jp' ) ) { +if ( ! function_exists( 'typecore_embed_html_jp' ) ) { - function alx_embed_html_jp( $html ) { + function typecore_embed_html_jp( $html ) { return '
' . $html . '
'; } } -add_filter( 'video_embed_html', 'alx_embed_html_jp' ); +add_filter( 'video_embed_html', 'typecore_embed_html_jp' ); /* Upscale cropped thumbnails /* ------------------------------------ */ -if ( ! function_exists( 'alx_thumbnail_upscale' ) ) { +if ( ! function_exists( 'typecore_thumbnail_upscale' ) ) { - function alx_thumbnail_upscale( $default, $orig_w, $orig_h, $new_w, $new_h, $crop ){ + function typecore_thumbnail_upscale( $default, $orig_w, $orig_h, $new_w, $new_h, $crop ){ if ( !$crop ) return null; // let the wordpress default function handle this $aspect_ratio = $orig_w / $orig_h; @@ -626,7 +626,7 @@ function alx_thumbnail_upscale( $default, $orig_w, $orig_h, $new_w, $new_h, $cro } } -add_filter( 'image_resize_dimensions', 'alx_thumbnail_upscale', 10, 6 ); +add_filter( 'image_resize_dimensions', 'typecore_thumbnail_upscale', 10, 6 ); /* ------------------------------------------------------------------------- * @@ -635,9 +635,9 @@ function alx_thumbnail_upscale( $default, $orig_w, $orig_h, $new_w, $new_h, $cro /* Include or exclude featured articles in loop /* ------------------------------------ */ -if ( ! function_exists( 'alx_pre_get_posts' ) ) { +if ( ! function_exists( 'typecore_pre_get_posts' ) ) { - function alx_pre_get_posts( $query ) { + function typecore_pre_get_posts( $query ) { // Are we on main query ? if ( !$query->is_main_query() ) return; if ( $query->is_home() ) { @@ -645,7 +645,7 @@ function alx_pre_get_posts( $query ) { // Featured posts enabled if ( get_theme_mod('featured-posts-count','3') != '0' ) { // Get featured post ids - $featured_post_ids = alx_get_featured_post_ids(); + $featured_post_ids = typecore_get_featured_post_ids(); // Exclude posts if ( $featured_post_ids && !get_theme_mod('featured-posts-include') ) $query->set('post__not_in', $featured_post_ids); @@ -654,26 +654,26 @@ function alx_pre_get_posts( $query ) { } } -add_action( 'pre_get_posts', 'alx_pre_get_posts' ); +add_action( 'pre_get_posts', 'typecore_pre_get_posts' ); /* Script for no-js / js class /* ------------------------------------ */ -if ( ! function_exists( 'alx_html_js_class' ) ) { +if ( ! function_exists( 'typecore_html_js_class' ) ) { - function alx_html_js_class () { + function typecore_html_js_class () { echo ''. "\n"; } } -add_action( 'wp_head', 'alx_html_js_class', 1 ); +add_action( 'wp_head', 'typecore_html_js_class', 1 ); /* IE js header /* ------------------------------------ */ -if ( ! function_exists( 'alx_ie_js_header' ) ) { +if ( ! function_exists( 'typecore_ie_js_header' ) ) { - function alx_ie_js_header () { + function typecore_ie_js_header () { echo ''. "\n"; } } -add_action( 'wp_footer', 'alx_ie_js_footer', 20 ); +add_action( 'wp_footer', 'typecore_ie_js_footer', 20 ); /* TGM plugin activation /* ------------------------------------ */ -if ( ! function_exists( 'alx_plugins' ) ) { +if ( ! function_exists( 'typecore_plugins' ) ) { - function alx_plugins() { + function typecore_plugins() { if ( get_theme_mod('recommended-plugins','on') =='on' ) { // Add the following plugins $plugins = array( @@ -747,34 +747,34 @@ function alx_plugins() { } } -add_action( 'tgmpa_register', 'alx_plugins' ); +add_action( 'tgmpa_register', 'typecore_plugins' ); /* WooCommerce basic support /* ------------------------------------ */ -function alx_wc_wrapper_start() { +function typecore_wc_wrapper_start() { echo '
'; echo '
'; } -function alx_wc_wrapper_end() { +function typecore_wc_wrapper_end() { echo '
'; echo '
'; } remove_action( 'woocommerce_before_main_content', 'woocommerce_output_content_wrapper', 10); remove_action( 'woocommerce_after_main_content', 'woocommerce_output_content_wrapper_end', 10); -add_action('woocommerce_before_main_content', 'alx_wc_wrapper_start', 10); -add_action('woocommerce_after_main_content', 'alx_wc_wrapper_end', 10); +add_action('woocommerce_before_main_content', 'typecore_wc_wrapper_start', 10); +add_action('woocommerce_after_main_content', 'typecore_wc_wrapper_end', 10); /* Admin panel css /* ------------------------------------ */ -function alx_admin_panel_css() { +function typecore_admin_panel_css() { echo ''; } -add_action('admin_head', 'alx_admin_panel_css'); +add_action('admin_head', 'typecore_admin_panel_css'); /* ------------------------------------------------------------------------- * @@ -783,9 +783,9 @@ function alx_admin_panel_css() { /* Flexslider featured /* ------------------------------------ */ -if ( ! function_exists( 'alx_flexslider_featured' ) ) { +if ( ! function_exists( 'typecore_flexslider_featured' ) ) { - function alx_flexslider_featured() { + function typecore_flexslider_featured() { if( is_home() && !is_paged() && ( get_theme_mod('featured-posts-count','3') !='0') ) { @@ -819,14 +819,14 @@ function alx_flexslider_featured() { } } -add_action( 'wp_enqueue_scripts', 'alx_flexslider_featured' ); +add_action( 'wp_enqueue_scripts', 'typecore_flexslider_featured' ); /* Flexslider gallery post format /* ------------------------------------ */ -if ( ! function_exists( 'alx_flexslider_gallery' ) ) { +if ( ! function_exists( 'typecore_flexslider_gallery' ) ) { - function alx_flexslider_gallery() { + function typecore_flexslider_gallery() { if( is_single() && has_post_format( 'gallery' ) ) { @@ -859,5 +859,5 @@ function alx_flexslider_gallery() { } } -add_action( 'wp_enqueue_scripts', 'alx_flexslider_gallery' ); +add_action( 'wp_enqueue_scripts', 'typecore_flexslider_gallery' ); diff --git a/functions/documentation/documentation.html b/functions/documentation/documentation.html index 551167b..b1d38ff 100644 --- a/functions/documentation/documentation.html +++ b/functions/documentation/documentation.html @@ -370,10 +370,10 @@

05.1Using a Child Theme

This theme has been built with child themes in mind, and therefore all theme functions are pluggable - which means you can overwrite them by copying a function from the parent theme and pasting it into the child theme's functions.php, modify it as you wish - and it will use your modified function instead the original one.

Load certain functionality from the child theme instead

-

This only applies for files loaded from the parent theme's functions.php. Let's say we wish to load the responsive.css file from our child theme's directory instead. We then need to copy the alx_styles() function to functions.php of the child theme (not including add_action, add_filter or !function_exists - just the function).

+

This only applies for files loaded from the parent theme's functions.php. Let's say we wish to load the responsive.css file from our child theme's directory instead. We then need to copy the typecore_styles() function to functions.php of the child theme (not including add_action, add_filter or !function_exists - just the function).

Now we have this function in our child theme - but it makes absolutely no difference, and still loads all files from the parent theme.

-
function alx_styles() {
+
function typecore_styles() {
 	wp_enqueue_style( 'style', get_stylesheet_uri() );
 	if ( !get_theme_mod('responsive') ) { wp_enqueue_style( 'responsive', get_template_directory_uri().'/responsive.css' ); }
 	if ( get_theme_mod('custom') ) { wp_enqueue_style( 'custom', get_template_directory_uri().'/custom.css' ); }
@@ -382,14 +382,14 @@ 

Load certain functionality from the child theme instead

To load from the child theme instead, change get_template_directory_uri to get_stylesheet_directory_uri for the responsive.css file. The rest of the files will still load from the parent theme, as they use get_template_directory_uri. Like this:

-
function alx_styles() {
+
function typecore_styles() {
 	wp_enqueue_style( 'style', get_stylesheet_uri() );
 	if ( !get_theme_mod('responsive') ) { wp_enqueue_style( 'responsive', get_stylesheet_directory_uri().'/responsive.css' ); }
 	if ( get_theme_mod('custom') ) { wp_enqueue_style( 'custom', get_template_directory_uri().'/custom.css' ); }
 	wp_enqueue_style( 'font-awesome', get_template_directory_uri().'/fonts/font-awesome.min.css' );
 }
-

The same method would be used to change language files folder. You would then copy over the whole alx_load() function, but only modify this one line in it:

+

The same method would be used to change language files folder. You would then copy over the whole typecore_load() function, but only modify this one line in it:

// Load theme languages
 load_theme_textdomain( 'themename', get_template_directory().'/languages' );
@@ -410,7 +410,7 @@

Load certain functionality from the child theme instead

Disabling functions

You can also completely disable functionality with the child theme replacement method. Let's say you don't want the plugin installation notice in your admin panel, or the "Install Plugins" item in your menu. All you would need to add is this to your child theme's functions.php:

-
function alx_plugins() { }
+
function typecore_plugins() { }

Simply emptying the function, disabling it completely.

Replacing page templates

@@ -542,14 +542,14 @@

Adding CSS to custom.css

05.4Change Thumbnail Size

-

To modify the custom thumbnail sizes for your theme, you need to copy over the whole function alx_setup() {} to your child theme, using the methods explained above.

+

To modify the custom thumbnail sizes for your theme, you need to copy over the whole function typecore_setup() {} to your child theme, using the methods explained above.

Within this function you will find the thumbnail sizes under where it says:

// Thumbnail sizes

Modify the height and width values as you want, using add_image_size codex as guideline to how it works. After that you've changed size and saved, you need to run the regenerate thumbnails plugin once before you will see any difference.

-

Important: If you have trouble with the way thumbnails are upscaling to fit the desired width or height before being cropped, you need to disable the alx_thumbnail_upscale function. You do so by adding function alx_thumbnail_upscale() {} to your child theme's functions.php, disabling the function completely.

+

Important: If you have trouble with the way thumbnails are upscaling to fit the desired width or height before being cropped, you need to disable the typecore_thumbnail_upscale function. You do so by adding function typecore_thumbnail_upscale() {} to your child theme's functions.php, disabling the function completely.

diff --git a/functions/dynamic-styles.php b/functions/dynamic-styles.php index 064d0c7..3d82c78 100644 --- a/functions/dynamic-styles.php +++ b/functions/dynamic-styles.php @@ -5,9 +5,9 @@ /* Convert hexadecimal to rgb /* ------------------------------------ */ -if ( ! function_exists( 'alx_hex2rgb' ) ) { +if ( ! function_exists( 'typecore_hex2rgb' ) ) { - function alx_hex2rgb( $hex, $array=false ) { + function typecore_hex2rgb( $hex, $array=false ) { $hex = str_replace("#", "", $hex); if ( strlen($hex) == 3 ) { @@ -30,9 +30,9 @@ function alx_hex2rgb( $hex, $array=false ) { /* Google fonts /* ------------------------------------ */ -if ( ! function_exists( 'alx_enqueue_google_fonts' ) ) { +if ( ! function_exists( 'typecore_enqueue_google_fonts' ) ) { - function alx_enqueue_google_fonts () { + function typecore_enqueue_google_fonts () { if ( get_theme_mod('dynamic-styles', 'on') == 'on' ) { if ( get_theme_mod( 'font' ) == 'titillium-web-ext' ) { wp_enqueue_style( 'titillium-web-ext', '//fonts.googleapis.com/css?family=Titillium+Web:400,400italic,300italic,300,600&subset=latin,latin-ext' ); } if ( get_theme_mod( 'font' ) == 'droid-serif' ) { wp_enqueue_style( 'droid-serif', '//fonts.googleapis.com/css?family=Droid+Serif:400,400italic,700' ); } @@ -57,19 +57,19 @@ function alx_enqueue_google_fonts () { } } -add_action( 'wp_enqueue_scripts', 'alx_enqueue_google_fonts' ); +add_action( 'wp_enqueue_scripts', 'typecore_enqueue_google_fonts' ); /* Dynamic css output /* ------------------------------------ */ -if ( ! function_exists( 'alx_dynamic_css' ) ) { +if ( ! function_exists( 'typecore_dynamic_css' ) ) { - function alx_dynamic_css() { + function typecore_dynamic_css() { if ( get_theme_mod('dynamic-styles', 'on') == 'on' ) { // rgb values $color_1 = get_theme_mod('color-1'); - $color_1_rgb = alx_hex2rgb($color_1); + $color_1_rgb = typecore_hex2rgb($color_1); // start output $styles = ''; @@ -270,4 +270,4 @@ function alx_dynamic_css() { } } -add_action( 'wp_enqueue_scripts', 'alx_dynamic_css' ); +add_action( 'wp_enqueue_scripts', 'typecore_dynamic_css' ); diff --git a/functions/meta-boxes.php b/functions/meta-boxes.php index d005fe2..229c49d 100644 --- a/functions/meta-boxes.php +++ b/functions/meta-boxes.php @@ -1,5 +1,5 @@ 'switch', 'settings' => 'custom', 'label' => esc_attr__( 'Custom Stylesheet', 'typecore' ), @@ -82,7 +82,7 @@ 'default' => 'off', ) ); // General: Responsive Layout -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'responsive', 'label' => esc_attr__( 'Responsive Layout', 'typecore' ), @@ -91,7 +91,7 @@ 'default' => 'on', ) ); // General: Mobile Sidebar -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'mobile-sidebar-hide', 'label' => esc_attr__( 'Mobile Sidebar Content', 'typecore' ), @@ -100,7 +100,7 @@ 'default' => 'on', ) ); // General: Mobile Sidebar -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio', 'settings' => 'mobile-sidebar-hide', 'label' => esc_attr__( 'Mobile Sidebar Content', 'typecore' ), @@ -115,7 +115,7 @@ ), ) ); // General: RSS Feed -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'text', 'settings' => 'rss-feed', 'label' => esc_attr__( 'FeedBurner URL', 'typecore' ), @@ -124,7 +124,7 @@ 'default' => '', ) ); // General: Post Comments -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'post-comments', 'label' => esc_attr__( 'Post Comments', 'typecore' ), @@ -133,7 +133,7 @@ 'default' => 'on', ) ); // General: Page Comments -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'page-comments', 'label' => esc_attr__( 'Page Comments', 'typecore' ), @@ -142,7 +142,7 @@ 'default' => 'off', ) ); // General: Recommended Plugins -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'recommended-plugins', 'label' => esc_attr__( 'Recommended Plugins', 'typecore' ), @@ -151,7 +151,7 @@ 'default' => 'on', ) ); // Blog: Heading -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'text', 'settings' => 'blog-heading', 'label' => esc_attr__( 'Heading', 'typecore' ), @@ -160,7 +160,7 @@ 'default' => '', ) ); // Blog: Subheading -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'text', 'settings' => 'blog-subheading', 'label' => esc_attr__( 'Subheading', 'typecore' ), @@ -169,7 +169,7 @@ 'default' => '', ) ); // Blog: Excerpt Length -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'slider', 'settings' => 'excerpt-length', 'label' => esc_attr__( 'Excerpt Length', 'typecore' ), @@ -183,7 +183,7 @@ ), ) ); // Blog: Featured Posts Include -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'checkbox', 'settings' => 'featured-posts-include', 'label' => esc_attr__( 'Featured Posts', 'typecore' ), @@ -192,7 +192,7 @@ 'default' => false, ) ); // Blog: Featured Category -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 'featured-category', 'label' => esc_attr__( 'Featured Category', 'typecore' ), @@ -203,7 +203,7 @@ 'placeholder' => esc_attr__( 'Select a category', 'typecore' ), ) ); // Blog: Featured Post Count -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'slider', 'settings' => 'featured-posts-count', 'label' => esc_attr__( 'Featured Post Count', 'typecore' ), @@ -217,7 +217,7 @@ ), ) ); // Blog: Highlights -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'highlights', 'label' => esc_attr__( 'Highlights', 'typecore' ), @@ -226,7 +226,7 @@ 'default' => 'on', ) ); // Blog: Highlights Category -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 'highlight-category', 'label' => esc_attr__( 'Highlights Category', 'typecore' ), @@ -237,7 +237,7 @@ 'placeholder' => esc_attr__( 'Select a category', 'typecore' ), ) ); // Blog: Picks -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'picks', 'label' => esc_attr__( 'Picks', 'typecore' ), @@ -246,7 +246,7 @@ 'default' => 'on', ) ); // Blog: Picks Category -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 'picks-category', 'label' => esc_attr__( 'Picks Category', 'typecore' ), @@ -257,7 +257,7 @@ 'placeholder' => esc_attr__( 'Select a category', 'typecore' ), ) ); // Blog: Frontpage Widgets Top -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'frontpage-widgets-top', 'label' => esc_attr__( 'Frontpage Widgets Top', 'typecore' ), @@ -266,7 +266,7 @@ 'default' => 'off', ) ); // Blog: Frontpage Widgets Bottom -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'frontpage-widgets-bottom', 'label' => esc_attr__( 'Frontpage Widgets Bottom', 'typecore' ), @@ -275,7 +275,7 @@ 'default' => 'off', ) ); // Blog: Standard -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'blog-standard', 'label' => esc_attr__( 'Standard Blog List', 'typecore' ), @@ -284,7 +284,7 @@ 'default' => 'off', ) ); // Blog: Thumbnail Placeholder -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'placeholder', 'label' => esc_attr__( 'Thumbnail Placeholder', 'typecore' ), @@ -293,7 +293,7 @@ 'default' => 'on', ) ); // Blog: Thumbnail Comment Count -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'comment-count', 'label' => esc_attr__( 'Thumbnail Comment Count', 'typecore' ), @@ -303,7 +303,7 @@ ) ); if( function_exists( 'alx_ext_sharrre_template' ) ) { // Blog: Twitter Username - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'text', 'settings' => 'twitter-username', 'label' => esc_attr__( 'Single - Share Bar - Twitter Username', 'typecore' ), @@ -313,7 +313,7 @@ ) ); } // Blog: Single - Authorbox -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'author-bio', 'label' => esc_attr__( 'Single - Author Bio', 'typecore' ), @@ -322,7 +322,7 @@ 'default' => 'on', ) ); // Blog: Single - Related Posts -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio', 'settings' => 'related-posts', 'label' => esc_attr__( 'Single - Related Posts', 'typecore' ), @@ -336,7 +336,7 @@ ), ) ); // Blog: Single - Post Navigation -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio', 'settings' => 'post-nav', 'label' => esc_attr__( 'Single - Post Navigation', 'typecore' ), @@ -351,7 +351,7 @@ ), ) ); // Header: Ads -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'header-ads', 'label' => esc_attr__( 'Header Ads', 'typecore' ), @@ -360,7 +360,7 @@ 'default' => 'off', ) ); // Header: Search -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'header-search', 'label' => esc_attr__( 'Header Search', 'typecore' ), @@ -369,7 +369,7 @@ 'default' => 'on', ) ); // Header: Social Links -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'header-social', 'label' => esc_attr__( 'Header Social Links', 'typecore' ), @@ -378,7 +378,7 @@ 'default' => 'on', ) ); // Header: Custom Logo -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'image', 'settings' => 'custom-logo', 'label' => esc_attr__( 'Custom Logo', 'typecore' ), @@ -387,7 +387,7 @@ 'default' => '', ) ); // Header: Site Description -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'site-description', 'label' => esc_attr__( 'Site Description', 'typecore' ), @@ -396,7 +396,7 @@ 'default' => 'on', ) ); // Header: Header Image -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'image', 'settings' => 'header-image', 'label' => esc_attr__( 'Header Image', 'typecore' ), @@ -405,7 +405,7 @@ 'default' => '', ) ); // Footer: Ads -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'footer-ads', 'label' => esc_attr__( 'Footer Ads', 'typecore' ), @@ -414,7 +414,7 @@ 'default' => 'off', ) ); // Footer: Widget Columns -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'footer-widgets', 'label' => esc_attr__( 'Footer Widget Columns', 'typecore' ), @@ -430,7 +430,7 @@ ), ) ); // Footer: Social Links -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'footer-social', 'label' => esc_attr__( 'Footer Social Links', 'typecore' ), @@ -439,7 +439,7 @@ 'default' => 'on', ) ); // Footer: Custom Logo -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'image', 'settings' => 'footer-logo', 'label' => esc_attr__( 'Footer Logo', 'typecore' ), @@ -448,7 +448,7 @@ 'default' => '', ) ); // Footer: Copyright -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'text', 'settings' => 'copyright', 'label' => esc_attr__( 'Footer Copyright', 'typecore' ), @@ -457,7 +457,7 @@ 'default' => '', ) ); // Footer: Credit -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'credit', 'label' => esc_attr__( 'Footer Credit', 'typecore' ), @@ -466,7 +466,7 @@ 'default' => 'on', ) ); // Layout: Global -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-global', 'label' => esc_attr__( 'Global Layout', 'typecore' ), @@ -483,7 +483,7 @@ ), ) ); // Layout: Home -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-home', 'label' => esc_attr__( 'Home', 'typecore' ), @@ -501,7 +501,7 @@ ), ) ); // Layout: Single -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-single', 'label' => esc_attr__( 'Single', 'typecore' ), @@ -519,7 +519,7 @@ ), ) ); // Layout: Archive -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-archive', 'label' => esc_attr__( 'Archive', 'typecore' ), @@ -537,7 +537,7 @@ ), ) ); // Layout : Archive - Category -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-archive-category', 'label' => esc_attr__( 'Archive - Category', 'typecore' ), @@ -555,7 +555,7 @@ ), ) ); // Layout: Search -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-search', 'label' => esc_attr__( 'Search', 'typecore' ), @@ -573,7 +573,7 @@ ), ) ); // Layout: Error 404 -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-404', 'label' => esc_attr__( 'Error 404', 'typecore' ), @@ -591,7 +591,7 @@ ), ) ); // Layout: Default Page -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio-image', 'settings' => 'layout-page', 'label' => esc_attr__( 'Default Page', 'typecore' ), @@ -609,7 +609,7 @@ ), ) ); // Sidebars: Create Sidebars -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'repeater', 'label' => esc_attr__( 'Create Sidebars', 'typecore' ), 'description' => esc_attr__( 'You must save and refresh the page to see your new sidebars.', 'typecore' ), @@ -638,7 +638,7 @@ ) ); -function alx_kirki_sidebars_select() { +function typecore_kirki_sidebars_select() { $sidebars = array(); if ( isset( $GLOBALS['wp_registered_sidebars'] ) ) { $sidebars = $GLOBALS['wp_registered_sidebars']; @@ -651,7 +651,7 @@ function alx_kirki_sidebars_select() { return; } // Sidebars: Select - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-home', 'label' => esc_attr__( 'Home', 'typecore' ), @@ -661,7 +661,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-home', 'label' => esc_attr__( 'Home', 'typecore' ), @@ -671,7 +671,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-single', 'label' => esc_attr__( 'Single', 'typecore' ), @@ -681,7 +681,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-single', 'label' => esc_attr__( 'Single', 'typecore' ), @@ -691,7 +691,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-archive', 'label' => esc_attr__( 'Archive', 'typecore' ), @@ -701,7 +701,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-archive', 'label' => esc_attr__( 'Archive', 'typecore' ), @@ -711,7 +711,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-archive-category', 'label' => esc_attr__( 'Archive - Category', 'typecore' ), @@ -721,7 +721,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-archive-category', 'label' => esc_attr__( 'Archive - Category', 'typecore' ), @@ -731,7 +731,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-search', 'label' => esc_attr__( 'Search', 'typecore' ), @@ -741,7 +741,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-search', 'label' => esc_attr__( 'Search', 'typecore' ), @@ -751,7 +751,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-404', 'label' => esc_attr__( 'Error 404', 'typecore' ), @@ -761,7 +761,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-404', 'label' => esc_attr__( 'Error 404', 'typecore' ), @@ -771,7 +771,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's1-page', 'label' => esc_attr__( 'Default Page', 'typecore' ), @@ -781,7 +781,7 @@ function alx_kirki_sidebars_select() { 'default' => '', 'placeholder' => esc_attr__( 'Select a sidebar', 'typecore' ), ) ); - Kirki::add_field( 'alx_theme', array( + Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 's2-page', 'label' => esc_attr__( 'Default Page', 'typecore' ), @@ -793,10 +793,10 @@ function alx_kirki_sidebars_select() { ) ); } -add_action( 'init', 'alx_kirki_sidebars_select', 999 ); +add_action( 'init', 'typecore_kirki_sidebars_select', 999 ); // Social Links: List -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'repeater', 'label' => esc_attr__( 'Create Social Links', 'typecore' ), 'description' => esc_attr__( 'Create and organize your social links', 'typecore' ), @@ -842,7 +842,7 @@ function alx_kirki_sidebars_select() { ) ) ); // Styling: Enable -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'dynamic-styles', 'label' => esc_attr__( 'Dynamic Styles', 'typecore' ), @@ -851,7 +851,7 @@ function alx_kirki_sidebars_select() { 'default' => 'on', ) ); // Styling: Centered Layout -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'center', 'label' => esc_attr__( 'Center Layout', 'typecore' ), @@ -860,7 +860,7 @@ function alx_kirki_sidebars_select() { 'default' => 'off', ) ); // Styling: Boxed Layout -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'switch', 'settings' => 'boxed', 'label' => esc_attr__( 'Boxed Layout', 'typecore' ), @@ -869,7 +869,7 @@ function alx_kirki_sidebars_select() { 'default' => 'off', ) ); // Styling: Font -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'select', 'settings' => 'font', 'label' => esc_attr__( 'Font', 'typecore' ), @@ -904,7 +904,7 @@ function alx_kirki_sidebars_select() { ), ) ); // Styling: Container Width -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'slider', 'settings' => 'container-width', 'label' => esc_attr__( 'Website Max-width', 'typecore' ), @@ -918,7 +918,7 @@ function alx_kirki_sidebars_select() { ), ) ); // Styling: Sidebar Width -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'radio', 'settings' => 'sidebar-padding', 'label' => esc_attr__( 'Sidebar Width', 'typecore' ), @@ -931,7 +931,7 @@ function alx_kirki_sidebars_select() { ), ) ); // Styling: Primary Color -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-1', 'label' => esc_attr__( 'Primary Color', 'typecore' ), @@ -940,7 +940,7 @@ function alx_kirki_sidebars_select() { 'default' => '#e64338', ) ); // Styling: Comments Bubble -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-bubble', 'label' => esc_attr__( 'Comments Bubble', 'typecore' ), @@ -949,7 +949,7 @@ function alx_kirki_sidebars_select() { 'default' => '#f7e696', ) ); // Styling: Mobile Menu Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-mobile-menu', 'label' => esc_attr__( 'Mobile Menu Background', 'typecore' ), @@ -958,7 +958,7 @@ function alx_kirki_sidebars_select() { 'default' => '#e64338', ) ); // Styling: Topbar Menu Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-topbar-menu', 'label' => esc_attr__( 'Topbar Menu Background', 'typecore' ), @@ -967,7 +967,7 @@ function alx_kirki_sidebars_select() { 'default' => '#e64338', ) ); // Styling: Header Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-header', 'label' => esc_attr__( 'Header Background', 'typecore' ), @@ -976,7 +976,7 @@ function alx_kirki_sidebars_select() { 'default' => '#23282d', ) ); // Styling: Header Menu Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-header-menu', 'label' => esc_attr__( 'Header Menu Background', 'typecore' ), @@ -985,7 +985,7 @@ function alx_kirki_sidebars_select() { 'default' => '', ) ); // Styling: Footer Menu Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-footer-menu', 'label' => esc_attr__( 'Footer Menu Background', 'typecore' ), @@ -994,7 +994,7 @@ function alx_kirki_sidebars_select() { 'default' => '', ) ); // Styling: Footer Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'color', 'settings' => 'color-footer', 'label' => esc_attr__( 'Footer Background', 'typecore' ), @@ -1003,7 +1003,7 @@ function alx_kirki_sidebars_select() { 'default' => '#e64338', ) ); // Styling: Header Logo Max-height -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'slider', 'settings' => 'logo-max-height', 'label' => esc_attr__( 'Header Logo Image Max-height', 'typecore' ), @@ -1017,7 +1017,7 @@ function alx_kirki_sidebars_select() { ), ) ); // Styling: Image Border Radius -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'slider', 'settings' => 'image-border-radius', 'label' => esc_attr__( 'Image Border Radius', 'typecore' ), @@ -1031,7 +1031,7 @@ function alx_kirki_sidebars_select() { ), ) ); // Styling: Body Background -Kirki::add_field( 'alx_theme', array( +Kirki::add_field( 'typecore_theme', array( 'type' => 'background', 'settings' => 'body-background', 'label' => esc_attr__( 'Body Background', 'typecore' ), diff --git a/functions/widgets/alx-posts.php b/functions/widgets/alx-posts.php index 498bae6..dca5fef 100644 --- a/functions/widgets/alx-posts.php +++ b/functions/widgets/alx-posts.php @@ -16,7 +16,7 @@ class AlxPosts extends WP_Widget { /* Constructor /* ------------------------------------ */ function __construct() { - parent::__construct( false, 'AlxPosts', array('description' => 'Display posts from a category', 'classname' => 'widget_alx_posts') );; + parent::__construct( false, 'AlxPosts', array('description' => 'Display posts from a category', 'classname' => 'widget_typecore_posts') );; } /* Widget @@ -187,11 +187,11 @@ public function form($instance) { /* Register widget /* ------------------------------------ */ -if ( ! function_exists( 'alx_register_widget_posts' ) ) { +if ( ! function_exists( 'typecore_register_widget_posts' ) ) { - function alx_register_widget_posts() { + function typecore_register_widget_posts() { register_widget( 'AlxPosts' ); } } -add_action( 'widgets_init', 'alx_register_widget_posts' ); +add_action( 'widgets_init', 'typecore_register_widget_posts' ); diff --git a/functions/widgets/alx-tabs.php b/functions/widgets/alx-tabs.php index d9dd45a..2c690fe 100644 --- a/functions/widgets/alx-tabs.php +++ b/functions/widgets/alx-tabs.php @@ -16,7 +16,7 @@ class AlxTabs extends WP_Widget { /* Constructor /* ------------------------------------ */ function __construct() { - parent::__construct( false, 'AlxTabs', array('description' => 'List posts, comments, and/or tags with or without tabs.', 'classname' => 'widget_alx_tabs') );; + parent::__construct( false, 'AlxTabs', array('description' => 'List posts, comments, and/or tags with or without tabs.', 'classname' => 'widget_typecore_tabs') );; } /* Create tabs-nav @@ -407,11 +407,11 @@ public function form($instance) { /* Register widget /* ------------------------------------ */ -if ( ! function_exists( 'alx_register_widget_tabs' ) ) { +if ( ! function_exists( 'typecore_register_widget_tabs' ) ) { - function alx_register_widget_tabs() { + function typecore_register_widget_tabs() { register_widget( 'AlxTabs' ); } } -add_action( 'widgets_init', 'alx_register_widget_tabs' ); +add_action( 'widgets_init', 'typecore_register_widget_tabs' ); diff --git a/header.php b/header.php index c5ad454..8410e86 100644 --- a/header.php +++ b/header.php @@ -64,7 +64,7 @@
- +

@@ -97,7 +97,7 @@
\ No newline at end of file diff --git a/inc/page-title.php b/inc/page-title.php index 49dbb56..2e731b0 100644 --- a/inc/page-title.php +++ b/inc/page-title.php @@ -1,7 +1,7 @@
-

+

    @@ -12,7 +12,7 @@
-

+

diff --git a/inc/post-formats.php b/inc/post-formats.php index 23e936f..9d8aa2a 100644 --- a/inc/post-formats.php +++ b/inc/post-formats.php @@ -18,7 +18,7 @@
- +
diff --git a/inc/related-posts.php b/inc/related-posts.php index 18b94e8..24563b3 100644 --- a/inc/related-posts.php +++ b/inc/related-posts.php @@ -1,4 +1,4 @@ - + have_posts() ): ?> diff --git a/sidebar-2.php b/sidebar-2.php index e1322ba..56048c2 100644 --- a/sidebar-2.php +++ b/sidebar-2.php @@ -1,4 +1,4 @@ - +