manager->get_setting( 'aytias_options[enable_dark_mode]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_top_bar_enabled' ) ) : /** * Check if top bar is enabled * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * * @return bool Whether the control is active to the current preview. */ function aytias_is_top_bar_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[enable_top_bar]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_todays_date_enabled' ) ) : /** * Check if Todays Date is enabled * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * * @return bool Whether the control is active to the current preview. */ function aytias_is_todays_date_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[enable_todays_date]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_sticky_menu_enabled' ) ) : /** * Check if Sticky Menu is enabled * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * * @return bool Whether the control is active to the current preview. */ function aytias_is_sticky_menu_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[enable_sticky_menu]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_search_icon_enabled' ) ) : /** * Check if search icon is enabled to make settings active * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * */ function aytias_is_search_icon_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[enable_search_on_header]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_header_social_nav_enabled' ) ) : /** * Check for apporpirate header styles to make settings active * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * */ function aytias_is_header_social_nav_enabled( $control ) { $header_style = $control->manager->get_setting( 'aytias_options[header_style]' )->value(); $allowed_styles = array('header_style_6'); if ( in_array($header_style,$allowed_styles) ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_header_top_nav_enabled' ) ) : /** * Check for apporpirate header styles to make settings active * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * */ function aytias_is_header_top_nav_enabled( $control ) { $header_style = $control->manager->get_setting( 'aytias_options[header_style]' )->value(); $allowed_styles = array('header_style_6'); if ( in_array($header_style,$allowed_styles) ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_related_posts_enabled' ) ) : /** * Check if related Posts is active. * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * * @return bool Whether the control is active to the current preview. */ function aytias_is_related_posts_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[show_related_posts]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_author_posts_enabled' ) ) : /** * Check if author Posts is active. * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * * @return bool Whether the control is active to the current preview. */ function aytias_is_author_posts_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[show_author_posts]' )->value() === true ) { return true; } else { return false; } } endif; if ( ! function_exists( 'aytias_is_copyright_enabled' ) ) : /** * Check if copyright section is enabled * * @since 1.0.0 * * @param WP_Customize_Control $control WP_Customize_Control instance. * * @return bool Whether the control is active to the current preview. */ function aytias_is_copyright_enabled( $control ) { if ( $control->manager->get_setting( 'aytias_options[enable_copyright]' )->value() === true ) { return true; } else { return false; } } endif;