Changeset 207216
- Timestamp:
- 11/05/2023 05:53:12 AM (2 years ago)
- Location:
- motivational-speaker/3.0
- Files:
-
- 1 added
- 27 edited
- 1 copied
-
. (copied) (copied from motivational-speaker/2.9)
-
404.php (modified) (1 diff)
-
assets/css/custom-controls.css (modified) (1 diff)
-
assets/css/customize-controls.css (modified) (1 diff)
-
functions.php (modified) (11 diffs)
-
inc/custom-control.php (modified) (1 diff)
-
inc/custom-header.php (modified) (1 diff)
-
inc/customizer-home-page.php (added)
-
inc/customizer.php (modified) (17 diffs)
-
inc/extra_customization.php (modified) (1 diff)
-
page-template/left-sidebar.php (modified) (1 diff)
-
page-template/right-sidebar.php (modified) (1 diff)
-
page.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
style-rtl.css (modified) (12 diffs)
-
style.css (modified) (10 diffs)
-
template-parts/post/content-audio.php (modified) (2 diffs)
-
template-parts/post/content-gallery.php (modified) (2 diffs)
-
template-parts/post/content-image.php (modified) (2 diffs)
-
template-parts/post/content-quote.php (modified) (2 diffs)
-
template-parts/post/content-video.php (modified) (2 diffs)
-
template-parts/post/content.php (modified) (2 diffs)
-
template-parts/post/grid-audio.php (modified) (3 diffs)
-
template-parts/post/grid-gallery.php (modified) (2 diffs)
-
template-parts/post/grid-image.php (modified) (2 diffs)
-
template-parts/post/grid-quote.php (modified) (2 diffs)
-
template-parts/post/grid-video.php (modified) (3 diffs)
-
template-parts/post/grid.php (modified) (2 diffs)
-
template-parts/post/single-page.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
motivational-speaker/3.0/404.php
r159615 r207216 8 8 get_header(); ?> 9 9 10 <div class="container"> 11 <div id="primary" class="content-area mb-5"> 12 <main id="content" class="site-main" role="main"> 13 <section class="error-404 not-found"> 14 <header class="page-header"> 15 <h1 class="page-title"><?php esc_html_e( 'Oops! That page can’t be found.', 'motivational-speaker' ); ?></h1> 16 <div class="home-btn my-4"> 17 <a href="<?php echo esc_url( home_url() ); ?>" class="py-3 px-4"><?php esc_html_e( 'GO BACK', 'motivational-speaker' ); ?></a> 10 11 <div id="primary" class="content-area"> 12 <main class="site-main" role="main"> 13 <header class="page-header"> 14 <div class="header-image"></div> 15 <div class="internal-div"> 16 <?php //breadcrumb 17 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 18 if( get_option('motivational_speaker_enable_breadcrumb',false) != 'off'){ ?> 19 <div class="bread_crumb align-self-center text-center"> 20 <?php motivational_speaker_breadcrumb(); ?> 21 </div> 22 <?php } 23 }?> 24 <h1 class="page-title text-center my-5"><?php esc_html_e( 'Oops! That page can’t be found.', 'motivational-speaker' ); ?></h1> 25 <div class="home-btn text-center"> 26 <a href="<?php echo esc_url( home_url() ); ?>" class="py-3 px-4"><?php esc_html_e( 'GO BACK', 'motivational-speaker' ); ?></a> 27 </div> 28 </div> 29 </header> 30 <section class="error-404 not-found my-5"> 31 <div class="container"> 32 <div class="page-content"> 33 <p><?php esc_html_e( 'It looks like nothing was found at this location. Maybe try a search?', 'motivational-speaker' ); ?></p> 34 <?php get_search_form(); ?> 18 35 </div> 19 </header>20 <div class="page-content">21 <p><?php esc_html_e( 'It looks like nothing was found at this location. Maybe try a search?', 'motivational-speaker' ); ?></p>22 <?php get_search_form(); ?>23 36 </div> 24 37 </section> 25 38 </main> 26 39 </div> 27 </div>28 40 29 41 <?php get_footer(); -
motivational-speaker/3.0/assets/css/custom-controls.css
r203196 r207216 108 108 max-width: 64px; 109 109 } 110 /* ========================================================================== 111 Text Radio Buttons 112 ========================================================================== */ 113 .text_radio_button_control:after { 114 content: " "; 115 display: block; 116 clear: both; 117 } 118 .text_radio_button_control .radio-buttons { 119 display: inline-block; 120 } 121 .text_radio_button_control .radio-button-label > input { 122 display: none; 123 } 124 .text_radio_button_control .radio-button-label span { 125 background: rgba(0, 0, 0, 0.05); 126 border: 1px solid rgba(0, 0, 0, 0.1); 127 color: #555; 128 margin: 0; 129 text-align: center; 130 padding: 0.5em 2em; 131 flex-grow: 1; 132 } 133 .text_radio_button_control .radio-button-label span:hover { 134 background-color: #fff; 135 color: #2885bb; 136 } 137 .text_radio_button_control .radio-button-label > input:checked + span { 138 background-color: #3498DB; 139 color: #fff; 140 } 141 .text_radio_button_control .radio-button-label > input:checked + span:hover { 142 color: #fff; 143 } 144 li#customize-control-motivational_speaker_footer_widget .text_radio_button_control .radio-button-label span, 145 li#customize-control-motivational_speaker_grid_column .text_radio_button_control .radio-button-label span{ 146 padding: 0.5em 2.3em; 147 } 148 @media screen and (max-width: 1440px){ 149 .text_radio_button_control .radio-button-label span{ 150 padding: 0.5em 1.5em !important; 151 } 152 } -
motivational-speaker/3.0/assets/css/customize-controls.css
r185958 r207216 21 21 font-family: 'Font Awesome 5 Brands'; 22 22 } 23 ul#sub-accordion-section-motivational_speaker_theme_settings .selected-icon i { 23 ul#sub-accordion-section-motivational_speaker_archieve_post_layot .selected-icon .fas, 24 ul#sub-accordion-section-motivational_speaker_archieve_post_layot .selected-icon .far, 25 ul#sub-accordion-section-motivational_speaker_layout .selected-icon .far, 26 ul#sub-accordion-section-motivational_speaker_layout .selected-icon .fas, 27 ul#sub-accordion-section-motivational_speaker_theme_settings .selected-icon .fa{ 24 28 font-family: 'Font Awesome 5 Free'; 25 29 } -
motivational-speaker/3.0/functions.php
r205535 r207216 10 10 //shop page no of columns 11 11 function motivational_speaker_woocommerce_loop_columns() { 12 13 12 $retrun = get_theme_mod( 'motivational_speaker_archieve_item_columns', 3 ); 14 13 15 14 return $retrun; 16 15 } 17 18 16 add_filter( 'loop_shop_columns', 'motivational_speaker_woocommerce_loop_columns' ); 19 20 17 function motivational_speaker_woocommerce_products_per_page() { 21 18 … … 25 22 } 26 23 add_filter( 'loop_shop_per_page', 'motivational_speaker_woocommerce_products_per_page' ); 27 28 24 // related products 29 25 function motivational_speaker_related_products_args( $args ) { … … 38 34 } 39 35 add_filter( 'woocommerce_output_related_products_args', 'motivational_speaker_related_products_args' ); 40 41 36 //woocommerce-end// 42 37 38 // get start function // 39 function motivational_speaker_notice(){ 40 global $pagenow; 41 if ( is_admin() && ('themes.php' == $pagenow) && isset( $_GET['activated'] ) ) { 42 wp_safe_redirect( admin_url("themes.php?page=motivational-speaker-guide-page") ); 43 } 44 } 45 add_action('after_setup_theme', 'motivational_speaker_notice'); 46 function motivational_speaker_add_new_page() { 47 $edit_page = admin_url().'post-new.php?post_type=page'; 48 echo json_encode(['page_id'=>'','edit_page_url'=> $edit_page ]); 49 50 exit; 51 } 52 add_action( 'wp_ajax_motivational_speaker_add_new_page','motivational_speaker_add_new_page' ); 53 //get-start-function-end// 54 55 // tag count 56 function display_post_tag_count() { 57 $tags = get_the_tags(); 58 $tag_count = ($tags) ? count($tags) : 0; 59 $tag_text = ($tag_count === 1) ? 'tag' : 'tags'; // Check for pluralization 60 echo $tag_count . ' ' . $tag_text; 61 } 62 63 //media post format 64 function motivational_speaker_get_media($type = array()){ 65 $content = apply_filters( 'the_content', get_the_content() ); 66 $output = false; 67 68 // Only get audio from the content if a playlist isn't present. 69 if ( false === strpos( $content, 'wp-playlist-script' ) ) { 70 $output = get_media_embedded_in_content( $content, $type ); 71 return $output; 72 } 73 } 74 75 // front page template 76 function motivational_speaker_front_page_template( $template ) { 77 return is_home() ? '' : $template; 78 } 79 add_filter( 'frontpage_template', 'motivational_speaker_front_page_template' ); 80 81 // excerpt function 82 function motivational_speaker_custom_excerpt() { 83 global $post; 84 $content = get_the_content(); // Use get_the_content to retrieve the full post content 85 $excerpt_length = get_theme_mod('motivational_speaker_post_excerpt', 30); // Get the excerpt length from the Customizer setting 86 87 // Use wp_trim_words to limit the content to the desired number of words 88 $excerpt = wp_trim_words($content, $excerpt_length); 89 90 $read_more_link = sprintf( 91 '<div class="link-more text-center"><a href="%s" class="more-link py-2 px-4">%s</a></div>', 92 esc_url(get_permalink(get_the_ID())), 93 /* translators: %s: Name of current post */ 94 sprintf(__('Read More<span class="screen-reader-text"> "%s"</span>', 'motivational-speaker'), get_the_title(get_the_ID())) 95 ); 96 97 echo $excerpt . $read_more_link; 98 } 99 100 // typograpgy 101 function motivational_speaker_fonts_scripts() { 102 $headings_font = esc_html(get_theme_mod('motivational_speaker_headings_text')); 103 $body_font = esc_html(get_theme_mod('motivational_speaker_body_text')); 104 105 if( $headings_font ) { 106 wp_enqueue_style( 'motivational-speaker-headings-fonts', '//fonts.googleapis.com/css?family='. $headings_font ); 107 } else { 108 wp_enqueue_style( 'motivational-speaker-be-vietnam', '//fonts.googleapis.com/css2?family=Be+Vietnam+Pro:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900'); 109 } 110 if( $body_font ) { 111 wp_enqueue_style( 'motivational-speaker-body-fonts', '//fonts.googleapis.com/css?family='. $body_font ); 112 } else { 113 wp_enqueue_style( 'motivational-speaker-be-vietnam', '//fonts.googleapis.com/css2?family=Be+Vietnam+Pro:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900'); 114 } 115 } 116 add_action( 'wp_enqueue_scripts', 'motivational_speaker_fonts_scripts' ); 117 118 // custom sanitizations 119 // dropdown 43 120 function motivational_speaker_sanitize_dropdown_pages( $page_id, $setting ) { 44 121 $page_id = absint( $page_id ); 45 122 return ( 'publish' == get_post_status( $page_id ) ? $page_id : $setting->default ); 46 123 } 47 48 function motivational_speaker_sanitize_checkbox( $input ) { 49 return ( ( isset( $input ) && true == $input ) ? true : false ); 50 } 51 124 // slider custom control 125 if ( ! function_exists( 'motivational_speaker_sanitize_integer' ) ) { 126 function motivational_speaker_sanitize_integer( $input ) { 127 return (int) $input; 128 } 129 } 130 // range contol 131 function motivational_speaker_sanitize_number_absint( $number, $setting ) { 132 133 // Ensure input is an absolute integer. 134 $number = absint( $number ); 135 136 // Get the input attributes associated with the setting. 137 $atts = $setting->manager->get_control( $setting->id )->input_attrs; 138 139 // Get minimum number in the range. 140 $min = ( isset( $atts['min'] ) ? $atts['min'] : $number ); 141 142 // Get maximum number in the range. 143 $max = ( isset( $atts['max'] ) ? $atts['max'] : $number ); 144 145 // Get step. 146 $step = ( isset( $atts['step'] ) ? $atts['step'] : 1 ); 147 148 // If the number is within the valid range, return it; otherwise, return the default 149 return ( $min <= $number && $number <= $max && is_int( $number / $step ) ? $number : $setting->default ); 150 } 151 // select post page 52 152 function motivational_speaker_sanitize_select( $input, $setting ){ 53 153 $input = sanitize_key($input); … … 55 155 return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); 56 156 } 57 if ( ! function_exists( 'motivational_speaker_sanitize_integer' ) ) { 58 function motivational_speaker_sanitize_integer( $input ) { 59 return (int) $input; 60 } 61 } 157 // toggle switch 158 function motivational_speaker_callback_sanitize_switch( $value ) { 159 // Switch values must be equal to 1 of off. Off is indicator and should not be translated. 160 return ( ( isset( $value ) && $value == 1 ) ? 1 : 'off' ); 161 } 162 //choices control 62 163 function motivational_speaker_sanitize_choices( $input, $setting ) { 63 164 global $wp_customize; … … 69 170 } 70 171 } 71 // post format functions 72 //media post format 73 function motivational_speaker_get_media($type = array()){ 74 $content = apply_filters( 'the_content', get_the_content() ); 75 $output = false; 76 77 // Only get audio from the content if a playlist isn't present. 78 if ( false === strpos( $content, 'wp-playlist-script' ) ) { 79 $output = get_media_embedded_in_content( $content, $type ); 80 return $output; 81 } 82 83 } 84 85 function motivational_speaker_callback_sanitize_switch( $value ) { 86 87 // Switch values must be equal to 1 of off. Off is indicator and should not be translated. 88 return ( ( isset( $value ) && $value == 1 ) ? 1 : 'off' ); 89 90 } 91 function motivational_speaker_sanitize_number_absint( $number, $setting ) { 92 93 // Ensure input is an absolute integer. 94 $number = absint( $number ); 95 96 // Get the input attributes associated with the setting. 97 $atts = $setting->manager->get_control( $setting->id )->input_attrs; 98 99 // Get minimum number in the range. 100 $min = ( isset( $atts['min'] ) ? $atts['min'] : $number ); 101 102 // Get maximum number in the range. 103 $max = ( isset( $atts['max'] ) ? $atts['max'] : $number ); 104 105 // Get step. 106 $step = ( isset( $atts['step'] ) ? $atts['step'] : 1 ); 107 108 // If the number is within the valid range, return it; otherwise, return the default 109 return ( $min <= $number && $number <= $max && is_int( $number / $step ) ? $number : $setting->default ); 110 } 111 172 // phone number 112 173 function motivational_speaker_sanitize_phone_number( $phone ) { 113 174 return preg_replace( '/[^\d+]/', '', $phone ); 114 175 } 115 176 116 function motivational_speaker_excerpt_more( $link ) { 117 if ( is_admin() ) { 118 return $link; 119 } 120 121 $link = sprintf( 122 '<div class="link-more text-center"><a href="%1$s" class="more-link py-2 px-4">%2$s</a></div>', 123 esc_url( get_permalink( get_the_ID() ) ), 124 /* translators: %s: Name of current post */ 125 sprintf( __( 'Read More<span class="screen-reader-text"> "%s"</span>', 'motivational-speaker' ), get_the_title( get_the_ID() ) ) 126 ); 127 return ' … ' . $link; 128 } 129 add_filter( 'excerpt_more', 'motivational_speaker_excerpt_more' ); 130 131 function motivational_speaker_notice(){ 132 global $pagenow; 133 if ( is_admin() && ('themes.php' == $pagenow) && isset( $_GET['activated'] ) ) { 134 wp_safe_redirect( admin_url("themes.php?page=motivational-speaker-guide-page") ); 135 } 136 } 137 add_action('after_setup_theme', 'motivational_speaker_notice'); 138 139 function motivational_speaker_add_new_page() { 140 $edit_page = admin_url().'post-new.php?post_type=page'; 141 echo json_encode(['page_id'=>'','edit_page_url'=> $edit_page ]); 142 143 exit; 144 } 145 add_action( 'wp_ajax_motivational_speaker_add_new_page','motivational_speaker_add_new_page' ); 146 177 // Customiser Sections Dropdown 178 function motivational_speaker_program_enable_dropdown(){ 179 if(get_option('motivational_speaker_program_enable') == true ) { 180 return true; 181 } 182 return false; 183 } 184 function motivational_speaker_slider_dropdown(){ 185 if(get_option('motivational_speaker_slider_arrows') == true ) { 186 return true; 187 } 188 return false; 189 } 190 191 //theme setup 147 192 function motivational_speaker_setup() { 148 149 193 add_theme_support( 'woocommerce' ); 150 194 add_theme_support( "align-wide" ); … … 194 238 */ 195 239 add_editor_style( array( 'assets/css/editor-style.css', motivational_speaker_fonts_url() ) ); 196 197 240 } 198 241 add_action( 'after_setup_theme', 'motivational_speaker_setup' ); 199 242 243 //widgets 200 244 function motivational_speaker_widgets_init() { 201 245 register_sidebar( array( … … 268 312 'after_title' => '</h3>', 269 313 ) ); 270 271 register_sidebar( array(272 'name' => __( 'Product Category Dropdown', 'motivational-speaker' ),273 'id' => 'product-cat',274 'description' => __( 'Add widgets here to appear in your header.', 'motivational-speaker' ),275 'before_widget' => '<section id="%1$s" class="widget %2$s">',276 'after_widget' => '</section>',277 'before_title' => '<h3 class="widget-title">',278 'after_title' => '</h3>',279 ) );280 314 } 281 315 add_action( 'widgets_init', 'motivational_speaker_widgets_init' ); 282 316 317 //google fonts 283 318 function motivational_speaker_fonts_url(){ 284 319 $font_url = ''; … … 296 331 //Enqueue scripts and styles. 297 332 function motivational_speaker_scripts() { 298 299 333 // Add custom fonts, used in the main stylesheet. 300 334 wp_enqueue_style( 'motivational-speaker-fonts', motivational_speaker_fonts_url(), array() ); … … 332 366 } 333 367 add_action( 'wp_enqueue_scripts', 'motivational_speaker_scripts' ); 334 335 function motivational_speaker_fonts_scripts() {336 $headings_font = esc_html(get_theme_mod('motivational_speaker_headings_text'));337 $body_font = esc_html(get_theme_mod('motivational_speaker_body_text'));338 339 if( $headings_font ) {340 wp_enqueue_style( 'motivational-speaker-headings-fonts', '//fonts.googleapis.com/css?family='. $headings_font );341 } else {342 wp_enqueue_style( 'motivational-speaker-be-vietnam', '//fonts.googleapis.com/css2?family=Be+Vietnam+Pro:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900');343 }344 if( $body_font ) {345 wp_enqueue_style( 'motivational-speaker-body-fonts', '//fonts.googleapis.com/css?family='. $body_font );346 } else {347 wp_enqueue_style( 'motivational-speaker-be-vietnam', '//fonts.googleapis.com/css2?family=Be+Vietnam+Pro:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900');348 }349 }350 add_action( 'wp_enqueue_scripts', 'motivational_speaker_fonts_scripts' );351 368 352 369 function motivational_speaker_enqueue_admin_script( $hook ) { … … 363 380 add_action( 'admin_enqueue_scripts', 'motivational_speaker_enqueue_admin_script' ); 364 381 365 // Enqueue editor styles for Gutenberg366 382 function motivational_speaker_block_editor_styles() { 367 383 // Block styles. … … 373 389 add_action( 'enqueue_block_editor_assets', 'motivational_speaker_block_editor_styles' ); 374 390 375 function motivational_speaker_front_page_template( $template ) {376 return is_home() ? '' : $template;377 }378 add_filter( 'frontpage_template', 'motivational_speaker_front_page_template' );379 380 require get_parent_theme_file_path( '/inc/custom-header.php' );381 382 require get_parent_theme_file_path( '/inc/template-tags.php' );383 384 require get_parent_theme_file_path( '/inc/template-functions.php' );385 386 require get_parent_theme_file_path( '/inc/customizer.php' );387 388 require get_parent_theme_file_path( '/inc/typofont.php' );389 390 require get_parent_theme_file_path( '/inc/dashboard/dashboard.php' );391 392 require get_parent_theme_file_path( '/inc/wptt-webfont-loader.php' );393 394 require get_parent_theme_file_path( '/inc/breadcrumb.php' );395 396 // Customiser Sections Dropdown397 398 399 function motivational_speaker_program_enable_dropdown(){400 if(get_option('motivational_speaker_program_enable') == true ) {401 return true;402 }403 return false;404 }405 function motivational_speaker_slider_dropdown(){406 if(get_option('motivational_speaker_slider_arrows') == true ) {407 return true;408 }409 return false;410 }411 412 391 # Load scripts and styles.(fontawesome) 413 392 add_action( 'customize_controls_enqueue_scripts', 'motivational_speaker_customize_controls_register_scripts' ); 414 415 393 function motivational_speaker_customize_controls_register_scripts() { 416 394 417 395 wp_enqueue_style( 'motivational-speaker-ctypo-customize-controls-style', trailingslashit( esc_url(get_template_directory_uri()) ) . '/assets/css/customize-controls.css' ); 418 396 } 397 398 //enque files 399 require get_parent_theme_file_path( '/inc/custom-header.php' ); 400 require get_parent_theme_file_path( '/inc/template-tags.php' ); 401 require get_parent_theme_file_path( '/inc/template-functions.php' ); 402 require get_parent_theme_file_path( '/inc/customizer.php' ); 403 require get_parent_theme_file_path( '/inc/typofont.php' ); 404 require get_parent_theme_file_path( '/inc/dashboard/dashboard.php' ); 405 require get_parent_theme_file_path( '/inc/wptt-webfont-loader.php' ); 406 require get_parent_theme_file_path( '/inc/breadcrumb.php' ); -
motivational-speaker/3.0/inc/custom-control.php
r203196 r207216 76 76 } 77 77 } 78 class Motivational_Speaker_Text_Radio_Button_Custom_Control extends WP_Customize_Control { 79 /** 80 * The type of control being rendered 81 */ 82 public $type = 'text_radio_button'; 83 /** 84 * Enqueue our scripts and styles 85 */ 86 public function enqueue() { 87 wp_enqueue_style( 'motivational-speaker-controls-css', trailingslashit( esc_url(get_template_directory_uri()) ) . 'assets/css/custom-controls.css', array(), '1.0', 'all' ); 88 } 89 /** 90 * Render the control in the customizer 91 */ 92 public function render_content() { ?> 93 <div class = 'text_radio_button_control'> 94 <?php if ( !empty( $this->label ) ) { ?> 95 <span class = 'customize-control-title'><?php echo esc_html( $this->label );?></span> 96 <?php }?> 97 <?php if ( !empty( $this->description ) ) { ?> 98 <span class = 'customize-control-description'><?php echo esc_html( $this->description ); ?></span> 99 <?php } ?> 100 <div class = 'radio-buttons'> 101 <?php foreach ( $this->choices as $key => $value ) { ?> 102 <label class = 'radio-button-label'> 103 <input type = 'radio' name = "<?php echo esc_attr( $this->id ); ?>" value = "<?php echo esc_attr( $key ); ?>" <?php $this->link();?><?php checked( esc_attr( $key ), $this->value() );?>/> 104 <span><?php echo esc_html( $value );?></span> 105 </label> 106 <?php }?> 107 </div> 108 </div> 109 <?php } 110 } -
motivational-speaker/3.0/inc/custom-header.php
r205535 r207216 37 37 if ( get_header_image() ) : 38 38 $custom_css = " 39 #header, .page-template-custom-home-page .wrap_figure{ 40 background-image:url('".esc_url(get_header_image())."'); 41 background-position: top; 42 height: auto !important; 43 background-size:cover !important; 44 background-repeat:no-repeat !important; 45 46 }.header-image, .woocommerce-page .single-post-image{ 39 .header-image, .woocommerce-page .single-post-image{ 47 40 background-image:url('".esc_url(get_header_image())."'); 48 41 background-position: top; -
motivational-speaker/3.0/inc/customizer.php
r205535 r207216 20 20 require get_parent_theme_file_path( 'inc/custom-control.php' ); 21 21 22 // Add homepage customizer file 23 require get_template_directory() . '/inc/customizer-home-page.php'; 24 25 // pro section 26 $wp_customize->add_section('motivational_speaker_pro', array( 27 'title' => __('UPGRADE MOTIVATIONAL PREMIUM', 'motivational-speaker'), 28 'priority' => 1, 29 )); 30 $wp_customize->add_setting('motivational_speaker_pro', array( 31 'default' => null, 32 'sanitize_callback' => 'sanitize_text_field', 33 )); 34 $wp_customize->add_control(new Motivational_Speaker_Pro_Control($wp_customize, 'motivational_speaker_pro', array( 35 'label' => __('MOTIVATIONAL SPEAKER PREMIUM', 'motivational-speaker'), 36 'section' => 'motivational_speaker_pro', 37 'settings' => 'motivational_speaker_pro', 38 'priority' => 1, 39 ))); 40 41 //Logo 42 $wp_customize->add_setting('motivational_speaker_logo_max_height',array( 43 'default'=> '100', 44 'transport' => 'refresh', 45 'sanitize_callback' => 'motivational_speaker_sanitize_integer' 46 )); 47 $wp_customize->add_control(new Motivational_Speaker_Slider_Custom_Control( $wp_customize, 'motivational_speaker_logo_max_height',array( 48 'label' => esc_html__('Logo Width','motivational-speaker'), 49 'section'=> 'title_tagline', 50 'settings'=>'motivational_speaker_logo_max_height', 51 'input_attrs' => array( 52 'reset' => 100, 53 'step' => 1, 54 'min' => 0, 55 'max' => 250, 56 ), 57 'priority' => 9, 58 ))); 59 $wp_customize->add_setting('motivational_speaker_logo_title', 60 array( 61 'type' => 'option', 62 'capability' => 'edit_theme_options', 63 'theme_supports' => '', 64 'default' => '1', 65 'transport' => 'refresh', 66 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 67 ) 68 ); 69 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 70 $wp_customize, 71 'motivational_speaker_logo_title', 72 array( 73 'settings' => 'motivational_speaker_logo_title', 74 'section' => 'title_tagline', 75 'label' => __( 'Show Site Title', 'motivational-speaker' ), 76 'choices' => array( 77 '1' => __( 'On', 'motivational-speaker' ), 78 'off' => __( 'Off', 'motivational-speaker' ), 79 ), 80 'active_callback' => '', 81 ) 82 ) 83 ); 84 $wp_customize->add_setting('motivational_speaker_logo_text', 85 array( 86 'type' => 'option', 87 'capability' => 'edit_theme_options', 88 'theme_supports' => '', 89 'default' => 'off', 90 'transport' => 'refresh', 91 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 92 ) 93 ); 94 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 95 $wp_customize, 96 'motivational_speaker_logo_text', 97 array( 98 'settings' => 'motivational_speaker_logo_text', 99 'section' => 'title_tagline', 100 'label' => __( 'Show Site Tagline', 'motivational-speaker' ), 101 'choices' => array( 102 '1' => __( 'On', 'motivational-speaker' ), 103 'off' => __( 'Off', 'motivational-speaker' ), 104 ), 105 'active_callback' => '', 106 ) 107 ) 108 ); 109 110 //typography 22 111 $wp_customize->add_section( 'motivational_speaker_typography_settings', array( 23 'title' => __( 'Typography ', 'motivational-speaker' ),112 'title' => __( 'Typography Settings', 'motivational-speaker' ), 24 113 'priority' => 2, 25 114 ) ); 26 27 115 $font_choices = array( 28 116 '' => 'Select', … … 57 145 'Yanone Kaffeesatz:400,700' => 'Yanone Kaffeesatz', 58 146 'Rokkitt:400' => 'Rokkitt', 59 ); 60 147 ); 61 148 $wp_customize->add_setting( 'motivational_speaker_section_typo_heading', array( 62 'default' => '', 63 'transport' => 'refresh', 64 'sanitize_callback' => 'sanitize_text_field', 65 ) ); 66 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_typo_heading', array( 67 'label' => esc_html__( 'Typography Settings', 'motivational-speaker' ), 68 'section' => 'motivational_speaker_typography_settings', 69 'settings' => 'motivational_speaker_section_typo_heading', 70 ) ) ); 71 72 149 'default' => '', 150 'transport' => 'refresh', 151 'sanitize_callback' => 'sanitize_text_field', 152 ) ); 153 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_typo_heading', array( 154 'label' => esc_html__( 'Typography Settings', 'motivational-speaker' ), 155 'section' => 'motivational_speaker_typography_settings', 156 'settings' => 'motivational_speaker_section_typo_heading', 157 ) ) ); 73 158 $wp_customize->add_setting( 'motivational_speaker_headings_text', array( 74 159 'sanitize_callback' => 'motivational_speaker_sanitize_fonts', … … 80 165 'choices' => $font_choices 81 166 )); 82 83 167 $wp_customize->add_setting( 'motivational_speaker_body_text', array( 84 168 'sanitize_callback' => 'motivational_speaker_sanitize_fonts' … … 91 175 ) ); 92 176 93 $wp_customize->add_section('motivational_speaker_pro', array(94 'title' => __('UPGRADE MOTIVATIONAL PREMIUM', 'motivational-speaker'),95 'priority' => 1,96 ));97 98 $wp_customize->add_setting('motivational_speaker_pro', array(99 'default' => null,100 'sanitize_callback' => 'sanitize_text_field',101 ));102 $wp_customize->add_control(new Motivational_Speaker_Pro_Control($wp_customize, 'motivational_speaker_pro', array(103 'label' => __('MOTIVATIONAL SPEAKER PREMIUM', 'motivational-speaker'),104 'section' => 'motivational_speaker_pro',105 'settings' => 'motivational_speaker_pro',106 'priority' => 1,107 )));108 109 //Logo110 $wp_customize->add_setting('motivational_speaker_logo_max_height',array(111 'default'=> '100',112 'transport' => 'refresh',113 'sanitize_callback' => 'motivational_speaker_sanitize_integer'114 ));115 $wp_customize->add_control(new Motivational_Speaker_Slider_Custom_Control( $wp_customize, 'motivational_speaker_logo_max_height',array(116 'label' => esc_html__('Logo Width','motivational-speaker'),117 'section'=> 'title_tagline',118 'settings'=>'motivational_speaker_logo_max_height',119 'input_attrs' => array(120 'reset' => 100,121 'step' => 1,122 'min' => 0,123 'max' => 250,124 ),125 )));126 127 $wp_customize->add_setting('motivational_speaker_logo_title',128 array(129 'type' => 'option',130 'capability' => 'edit_theme_options',131 'theme_supports' => '',132 'default' => '1',133 'transport' => 'refresh',134 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch',135 )136 );137 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch(138 $wp_customize,139 'motivational_speaker_logo_title',140 array(141 'settings' => 'motivational_speaker_logo_title',142 'section' => 'title_tagline',143 'label' => __( 'Show Site Title', 'motivational-speaker' ),144 'choices' => array(145 '1' => __( 'On', 'motivational-speaker' ),146 'off' => __( 'Off', 'motivational-speaker' ),147 ),148 'active_callback' => '',149 )150 )151 );152 153 $wp_customize->add_setting('motivational_speaker_logo_text',154 array(155 'type' => 'option',156 'capability' => 'edit_theme_options',157 'theme_supports' => '',158 'default' => 'off',159 'transport' => 'refresh',160 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch',161 )162 );163 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch(164 $wp_customize,165 'motivational_speaker_logo_text',166 array(167 'settings' => 'motivational_speaker_logo_text',168 'section' => 'title_tagline',169 'label' => __( 'Show Site Tagline', 'motivational-speaker' ),170 'choices' => array(171 '1' => __( 'On', 'motivational-speaker' ),172 'off' => __( 'Off', 'motivational-speaker' ),173 ),174 'active_callback' => '',175 )176 )177 );178 179 177 // Theme General Settings 180 178 $wp_customize->add_section('motivational_speaker_theme_settings',array( … … 182 180 'priority' => 2, 183 181 ) ); 184 185 182 $wp_customize->add_setting( 'motivational_speaker_sticky_heading', array( 186 'default' => '',187 'transport' => 'refresh',188 'sanitize_callback' => 'sanitize_text_field',189 ) );183 'default' => '', 184 'transport' => 'refresh', 185 'sanitize_callback' => 'sanitize_text_field', 186 ) ); 190 187 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_sticky_heading', array( 191 'label' => esc_html__( 'Sticky Header Settings', 'motivational-speaker' ), 192 'section' => 'motivational_speaker_theme_settings', 193 'settings' => 'motivational_speaker_sticky_heading', 194 ) ) ); 195 188 'label' => esc_html__( 'Sticky Header Settings', 'motivational-speaker' ), 189 'section' => 'motivational_speaker_theme_settings', 190 'settings' => 'motivational_speaker_sticky_heading', 191 ) ) ); 196 192 $wp_customize->add_setting( 197 193 'motivational_speaker_sticky_header', … … 221 217 ) 222 218 ); 223 224 219 $wp_customize->add_setting( 'motivational_speaker_loader_heading', array( 225 'default' => '',226 'transport' => 'refresh',227 'sanitize_callback' => 'sanitize_text_field',228 ) );220 'default' => '', 221 'transport' => 'refresh', 222 'sanitize_callback' => 'sanitize_text_field', 223 ) ); 229 224 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_loader_heading', array( 230 'label' => esc_html__( 'Loader Settings', 'motivational-speaker' ), 231 'section' => 'motivational_speaker_theme_settings', 232 'settings' => 'motivational_speaker_loader_heading', 233 ) ) ); 234 225 'label' => esc_html__( 'Loader Settings', 'motivational-speaker' ), 226 'section' => 'motivational_speaker_theme_settings', 227 'settings' => 'motivational_speaker_loader_heading', 228 ) ) ); 235 229 $wp_customize->add_setting( 236 230 'motivational_speaker_theme_loader', … … 260 254 ) 261 255 ); 256 $wp_customize->add_setting( 'motivational_speaker_theme_width_heading', array( 257 'default' => '', 258 'transport' => 'refresh', 259 'sanitize_callback' => 'sanitize_text_field', 260 ) ); 261 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_theme_width_heading', array( 262 'label' => esc_html__( 'Theme Width Settings', 'motivational-speaker' ), 263 'section' => 'motivational_speaker_theme_settings', 264 'settings' => 'motivational_speaker_theme_width_heading', 265 ) ) ); 266 $wp_customize->add_setting('motivational_speaker_width_options',array( 267 'default' => 'full_width', 268 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 269 )); 270 $wp_customize->add_control('motivational_speaker_width_options',array( 271 'type' => 'select', 272 'label' => __('Theme Width Option','motivational-speaker'), 273 'section' => 'motivational_speaker_theme_settings', 274 'choices' => array( 275 'full_width' => __('Fullwidth','motivational-speaker'), 276 'container' => __('Container','motivational-speaker'), 277 'container_fluid' => __('Container Fluid','motivational-speaker'), 278 ), 279 ) ); 262 280 $wp_customize->add_setting( 'motivational_speaker_menu_heading', array( 263 'default' => '',264 'transport' => 'refresh',265 'sanitize_callback' => 'sanitize_text_field',266 ) );281 'default' => '', 282 'transport' => 'refresh', 283 'sanitize_callback' => 'sanitize_text_field', 284 ) ); 267 285 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_menu_heading', array( 268 286 'label' => esc_html__( 'Menu Settings', 'motivational-speaker' ), … … 284 302 ), 285 303 ) ); 286 287 304 $wp_customize->add_setting( 'motivational_speaker_section_scroll_heading', array( 288 305 'default' => '', … … 295 312 'settings' => 'motivational_speaker_section_scroll_heading', 296 313 ) ) ); 297 298 314 $wp_customize->add_setting( 299 315 'motivational_speaker_scroll_enable', … … 323 339 ) 324 340 ); 325 326 $wp_customize->add_setting('motivational_speaker_scroll_options',array( 327 'default' => 'right_align', 328 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 329 )); 330 $wp_customize->add_control('motivational_speaker_scroll_options',array( 331 'type' => 'select', 332 'label' => __('Scroll Top Alignment','motivational-speaker'), 333 'section' => 'motivational_speaker_theme_settings', 334 'choices' => array( 335 'right_align' => __('Right Align','motivational-speaker'), 336 'center_align' => __('Center Align','motivational-speaker'), 337 'left_align' => __('Left Align','motivational-speaker'), 338 ), 339 ) ); 340 341 $wp_customize->add_setting( 'motivational_speaker_scroll_options', 342 array( 343 'default' => 'right_align', 344 'transport' => 'refresh', 345 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 346 ) 347 ); 348 $wp_customize->add_control( new Motivational_Speaker_Text_Radio_Button_Custom_Control( $wp_customize, 'motivational_speaker_scroll_options', 349 array( 350 'type' => 'select', 351 'label' => esc_html__( 'Scroll Top Alignment', 'motivational-speaker' ), 352 'section' => 'motivational_speaker_theme_settings', 353 'choices' => array( 354 'left_align' => __('LEFT','motivational-speaker'), 355 'center_align' => __('CENTER','motivational-speaker'), 356 'right_align' => __('RIGHT','motivational-speaker'), 357 ) 358 ) 359 ) ); 341 360 $wp_customize->add_setting('motivational_speaker_scroll_top_icon',array( 342 361 'default' => 'fas fa-chevron-up', … … 352 371 ))); 353 372 373 // Post Layouts 374 $wp_customize->add_panel( 'motivational_speaker_post_panel', array( 375 'title' => esc_html__( 'Post Layout', 'motivational-speaker' ), 376 'priority' => 3, 377 )); 378 $wp_customize->add_section('motivational_speaker_layout',array( 379 'title' => __('Single-Post Layout', 'motivational-speaker'), 380 'panel' => 'motivational_speaker_post_panel', 381 ) ); 382 $wp_customize->add_setting( 'motivational_speaker_section_post_heading', array( 383 'default' => '', 384 'transport' => 'refresh', 385 'sanitize_callback' => 'sanitize_text_field', 386 ) ); 387 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_post_heading', array( 388 'label' => esc_html__( 'single Post Structure', 'motivational-speaker' ), 389 'section' => 'motivational_speaker_layout', 390 'settings' => 'motivational_speaker_section_post_heading', 391 ) ) ); 392 $wp_customize->add_setting( 'motivational_speaker_single_post_option', 393 array( 394 'default' => 'single_right_sidebar', 395 'transport' => 'refresh', 396 'sanitize_callback' => 'sanitize_text_field' 397 ) 398 ); 399 $wp_customize->add_control( new Motivational_Speaker_Radio_Image_Control( $wp_customize, 'motivational_speaker_single_post_option', 400 array( 401 'type'=>'select', 402 'label' => __( 'select Single Post Page Layout', 'motivational-speaker' ), 403 'section' => 'motivational_speaker_layout', 404 'choices' => array( 405 406 'single_right_sidebar' => array( 407 'image' => get_template_directory_uri().'/assets/images/2column.jpg', 408 'name' => __( 'Right Sidebar', 'motivational-speaker' ) 409 ), 410 'single_left_sidebar' => array( 411 'image' => get_template_directory_uri().'/assets/images/left.png', 412 'name' => __( 'Left Sidebar', 'motivational-speaker' ) 413 ), 414 'single_full_width' => array( 415 'image' => get_template_directory_uri().'/assets/images/1column.jpg', 416 'name' => __( 'One Column', 'motivational-speaker' ) 417 ), 418 ) 419 ) 420 ) ); 421 $wp_customize->add_setting('motivational_speaker_single_post_date', 422 array( 423 'type' => 'option', 424 'capability' => 'edit_theme_options', 425 'theme_supports' => '', 426 'default' => '1', 427 'transport' => 'refresh', 428 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 429 ) 430 ); 431 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 432 $wp_customize, 433 'motivational_speaker_single_post_date', 434 array( 435 'settings' => 'motivational_speaker_single_post_date', 436 'section' => 'motivational_speaker_layout', 437 'label' => __( 'Show Date', 'motivational-speaker' ), 438 'choices' => array( 439 '1' => __( 'On', 'motivational-speaker' ), 440 'off' => __( 'Off', 'motivational-speaker' ), 441 ), 442 'active_callback' => '', 443 ) 444 ) 445 ); 446 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_single_post_date', array( 447 'selector' => '.date-box', 448 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_single_post_date', 449 ) ); 450 $wp_customize->add_setting('motivational_speaker_single_date_icon',array( 451 'default' => 'far fa-calendar-alt', 452 'sanitize_callback' => 'sanitize_text_field' 453 )); 454 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 455 $wp_customize,'motivational_speaker_single_date_icon',array( 456 'label' => __('date Icon','motivational-speaker'), 457 'transport' => 'refresh', 458 'section' => 'motivational_speaker_layout', 459 'setting' => 'motivational_speaker_single_date_icon', 460 'type' => 'icon' 461 ))); 462 $wp_customize->add_setting('motivational_speaker_single_post_admin', 463 array( 464 'type' => 'option', 465 'capability' => 'edit_theme_options', 466 'theme_supports' => '', 467 'default' => '1', 468 'transport' => 'refresh', 469 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 470 ) 471 ); 472 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 473 $wp_customize, 474 'motivational_speaker_single_post_admin', 475 array( 476 'settings' => 'motivational_speaker_single_post_admin', 477 'section' => 'motivational_speaker_layout', 478 'label' => __( 'Show Author/Admin', 'motivational-speaker' ), 479 'choices' => array( 480 '1' => __( 'On', 'motivational-speaker' ), 481 'off' => __( 'Off', 'motivational-speaker' ), 482 ), 483 'active_callback' => '', 484 ) 485 ) 486 ); 487 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_single_post_admin', array( 488 'selector' => '.entry-author', 489 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_single_post_admin', 490 ) ); 491 $wp_customize->add_setting('motivational_speaker_single_author_icon',array( 492 'default' => 'fas fa-user', 493 'sanitize_callback' => 'sanitize_text_field' 494 )); 495 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 496 $wp_customize,'motivational_speaker_single_author_icon',array( 497 'label' => __('Author Icon','motivational-speaker'), 498 'transport' => 'refresh', 499 'section' => 'motivational_speaker_layout', 500 'setting' => 'motivational_speaker_single_author_icon', 501 'type' => 'icon' 502 ))); 503 $wp_customize->add_setting('motivational_speaker_single_post_comment', 504 array( 505 'type' => 'option', 506 'capability' => 'edit_theme_options', 507 'theme_supports' => '', 508 'default' => '1', 509 'transport' => 'refresh', 510 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 511 ) 512 ); 513 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 514 $wp_customize, 515 'motivational_speaker_single_post_comment', 516 array( 517 'settings' => 'motivational_speaker_single_post_comment', 518 'section' => 'motivational_speaker_layout', 519 'label' => __( 'Show Comment', 'motivational-speaker' ), 520 'choices' => array( 521 '1' => __( 'On', 'motivational-speaker' ), 522 'off' => __( 'Off', 'motivational-speaker' ), 523 ), 524 'active_callback' => '', 525 ) 526 ) 527 ); 528 $wp_customize->add_setting('motivational_speaker_single_comment_icon',array( 529 'default' => 'fas fa-comments', 530 'sanitize_callback' => 'sanitize_text_field' 531 )); 532 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 533 $wp_customize,'motivational_speaker_single_comment_icon',array( 534 'label' => __('comment Icon','motivational-speaker'), 535 'transport' => 'refresh', 536 'section' => 'motivational_speaker_layout', 537 'setting' => 'motivational_speaker_single_comment_icon', 538 'type' => 'icon' 539 ))); 540 541 $wp_customize->add_setting('motivational_speaker_single_post_tag_count', 542 array( 543 'type' => 'option', 544 'capability' => 'edit_theme_options', 545 'theme_supports' => '', 546 'default' => '1', 547 'transport' => 'refresh', 548 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 549 ) 550 ); 551 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 552 $wp_customize, 553 'motivational_speaker_single_post_tag_count', 554 array( 555 'settings' => 'motivational_speaker_single_post_tag_count', 556 'section' => 'motivational_speaker_layout', 557 'label' => __( 'Show tag count', 'motivational-speaker' ), 558 'choices' => array( 559 '1' => __( 'On', 'motivational-speaker' ), 560 'off' => __( 'Off', 'motivational-speaker' ), 561 ), 562 'active_callback' => '', 563 ) 564 ) 565 ); 566 $wp_customize->add_setting('motivational_speaker_single_tag_icon',array( 567 'default' => 'fas fa-tags', 568 'sanitize_callback' => 'sanitize_text_field' 569 )); 570 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 571 $wp_customize,'motivational_speaker_single_tag_icon',array( 572 'label' => __('tag Icon','motivational-speaker'), 573 'transport' => 'refresh', 574 'section' => 'motivational_speaker_layout', 575 'setting' => 'motivational_speaker_single_tag_icon', 576 'type' => 'icon' 577 ))); 578 $wp_customize->add_setting('motivational_speaker_single_post_tag', 579 array( 580 'type' => 'option', 581 'capability' => 'edit_theme_options', 582 'theme_supports' => '', 583 'default' => '1', 584 'transport' => 'refresh', 585 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 586 ) 587 ); 588 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 589 $wp_customize, 590 'motivational_speaker_single_post_tag', 591 array( 592 'settings' => 'motivational_speaker_single_post_tag', 593 'section' => 'motivational_speaker_layout', 594 'label' => __( 'Show Tags', 'motivational-speaker' ), 595 'choices' => array( 596 '1' => __( 'On', 'motivational-speaker' ), 597 'off' => __( 'Off', 'motivational-speaker' ), 598 ), 599 'active_callback' => '', 600 ) 601 ) 602 ); 603 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_single_post_tag', array( 604 'selector' => '.single-tags', 605 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_single_post_tag', 606 ) ); 607 $wp_customize->add_section('motivational_speaker_archieve_post_layot',array( 608 'title' => __('Archieve-Post Layout', 'motivational-speaker'), 609 'panel' => 'motivational_speaker_post_panel', 610 ) ); 611 $wp_customize->add_setting( 'motivational_speaker_section_archive_post_heading', array( 612 'default' => '', 613 'transport' => 'refresh', 614 'sanitize_callback' => 'sanitize_text_field', 615 ) ); 616 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_archive_post_heading', array( 617 'label' => esc_html__( 'Archieve Post Structure', 'motivational-speaker' ), 618 'section' => 'motivational_speaker_archieve_post_layot', 619 'settings' => 'motivational_speaker_section_archive_post_heading', 620 ) ) ); 621 $wp_customize->add_setting( 'motivational_speaker_post_option', 622 array( 623 'default' => 'right_sidebar', 624 'transport' => 'refresh', 625 'sanitize_callback' => 'sanitize_text_field' 626 ) 627 ); 628 $wp_customize->add_control( new Motivational_Speaker_Radio_Image_Control( $wp_customize, 'motivational_speaker_post_option', 629 array( 630 'type'=>'select', 631 'label' => __( 'select Post Page Layout', 'motivational-speaker' ), 632 'section' => 'motivational_speaker_archieve_post_layot', 633 'choices' => array( 634 'right_sidebar' => array( 635 'image' => get_template_directory_uri().'/assets/images/2column.jpg', 636 'name' => __( 'Right Sidebar', 'motivational-speaker' ) 637 ), 638 'left_sidebar' => array( 639 'image' => get_template_directory_uri().'/assets/images/left.png', 640 'name' => __( 'Left Sidebar', 'motivational-speaker' ) 641 ), 642 'one_column' => array( 643 'image' => get_template_directory_uri().'/assets/images/1column.jpg', 644 'name' => __( 'One Column', 'motivational-speaker' ) 645 ), 646 'three_column' => array( 647 'image' => get_template_directory_uri().'/assets/images/3column.jpg', 648 'name' => __( 'Three Column', 'motivational-speaker' ) 649 ), 650 'four_column' => array( 651 'image' => get_template_directory_uri().'/assets/images/4column.jpg', 652 'name' => __( 'Four Column', 'motivational-speaker' ) 653 ), 654 'grid_sidebar' => array( 655 'image' => get_template_directory_uri().'/assets/images/grid-sidebar.jpg', 656 'name' => __( 'Grid-Sidebar Layout', 'motivational-speaker' ) 657 ), 658 'grid_left_sidebar' => array( 659 'image' => get_template_directory_uri().'/assets/images/grid-left.png', 660 'name' => __( 'Grid-Left-Sidebar Layout', 'motivational-speaker' ) 661 ), 662 'grid_post' => array( 663 'image' => get_template_directory_uri().'/assets/images/grid.jpg', 664 'name' => __( 'Grid Layout', 'motivational-speaker' ) 665 ) 666 ) 667 ) 668 ) ); 669 $wp_customize->add_setting( 'motivational_speaker_grid_column', 670 array( 671 'default' => '3_column', 672 'transport' => 'refresh', 673 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 674 ) 675 ); 676 $wp_customize->add_control( new Motivational_Speaker_Text_Radio_Button_Custom_Control( $wp_customize, 'motivational_speaker_grid_column', 677 array( 678 'type' => 'select', 679 'label' => esc_html__('Grid Post Per Row','motivational-speaker'), 680 'section' => 'motivational_speaker_archieve_post_layot', 681 'choices' => array( 682 '1_column' => __('1','motivational-speaker'), 683 '2_column' => __('2','motivational-speaker'), 684 '3_column' => __('3','motivational-speaker'), 685 '4_column' => __('4','motivational-speaker'), 686 ) 687 ) 688 ) ); 689 $wp_customize->add_setting('motivational_speaker_post_excerpt',array( 690 'default'=> 30, 691 'transport' => 'refresh', 692 'sanitize_callback' => 'motivational_speaker_sanitize_integer' 693 )); 694 $wp_customize->add_control(new Motivational_Speaker_Slider_Custom_Control( $wp_customize, 'motivational_speaker_post_excerpt',array( 695 'label' => esc_html__( 'Excerpt Limit','motivational-speaker' ), 696 'section'=> 'motivational_speaker_archieve_post_layot', 697 'settings'=>'motivational_speaker_post_excerpt', 698 'input_attrs' => array( 699 'reset' => 30, 700 'step' => 1, 701 'min' => 0, 702 'max' => 100, 703 ), 704 ))); 705 $wp_customize->add_setting('motivational_speaker_date', 706 array( 707 'type' => 'option', 708 'capability' => 'edit_theme_options', 709 'theme_supports' => '', 710 'default' => '1', 711 'transport' => 'refresh', 712 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 713 ) 714 ); 715 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 716 $wp_customize, 717 'motivational_speaker_date', 718 array( 719 'settings' => 'motivational_speaker_date', 720 'section' => 'motivational_speaker_archieve_post_layot', 721 'label' => __( 'Show Date', 'motivational-speaker' ), 722 'choices' => array( 723 '1' => __( 'On', 'motivational-speaker' ), 724 'off' => __( 'Off', 'motivational-speaker' ), 725 ), 726 'active_callback' => '', 727 ) 728 ) 729 ); 730 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_date', array( 731 'selector' => '.date-box', 732 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_date', 733 ) ); 734 $wp_customize->add_setting('motivational_speaker_date_icon',array( 735 'default' => 'far fa-calendar-alt', 736 'sanitize_callback' => 'sanitize_text_field' 737 )); 738 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 739 $wp_customize,'motivational_speaker_date_icon',array( 740 'label' => __('date Icon','motivational-speaker'), 741 'transport' => 'refresh', 742 'section' => 'motivational_speaker_archieve_post_layot', 743 'setting' => 'motivational_speaker_date_icon', 744 'type' => 'icon' 745 ))); 746 $wp_customize->add_setting('motivational_speaker_admin', 747 array( 748 'type' => 'option', 749 'capability' => 'edit_theme_options', 750 'theme_supports' => '', 751 'default' => '1', 752 'transport' => 'refresh', 753 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 754 ) 755 ); 756 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 757 $wp_customize, 758 'motivational_speaker_admin', 759 array( 760 'settings' => 'motivational_speaker_admin', 761 'section' => 'motivational_speaker_archieve_post_layot', 762 'label' => __( 'Show Author/Admin', 'motivational-speaker' ), 763 'choices' => array( 764 '1' => __( 'On', 'motivational-speaker' ), 765 'off' => __( 'Off', 'motivational-speaker' ), 766 ), 767 'active_callback' => '', 768 ) 769 ) 770 ); 771 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_admin', array( 772 'selector' => '.entry-author', 773 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_admin', 774 ) ); 775 $wp_customize->add_setting('motivational_speaker_author_icon',array( 776 'default' => 'fas fa-user', 777 'sanitize_callback' => 'sanitize_text_field' 778 )); 779 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 780 $wp_customize,'motivational_speaker_author_icon',array( 781 'label' => __('Author Icon','motivational-speaker'), 782 'transport' => 'refresh', 783 'section' => 'motivational_speaker_archieve_post_layot', 784 'setting' => 'motivational_speaker_author_icon', 785 'type' => 'icon' 786 ))); 787 $wp_customize->add_setting('motivational_speaker_comment', 788 array( 789 'type' => 'option', 790 'capability' => 'edit_theme_options', 791 'theme_supports' => '', 792 'default' => '1', 793 'transport' => 'refresh', 794 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 795 ) 796 ); 797 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 798 $wp_customize, 799 'motivational_speaker_comment', 800 array( 801 'settings' => 'motivational_speaker_comment', 802 'section' => 'motivational_speaker_archieve_post_layot', 803 'label' => __( 'Show Comment', 'motivational-speaker' ), 804 'choices' => array( 805 '1' => __( 'On', 'motivational-speaker' ), 806 'off' => __( 'Off', 'motivational-speaker' ), 807 ), 808 'active_callback' => '', 809 ) 810 ) 811 ); 812 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_comment', array( 813 'selector' => '.entry-comments', 814 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_comment', 815 ) ); 816 $wp_customize->add_setting('motivational_speaker_comment_icon',array( 817 'default' => 'fas fa-comments', 818 'sanitize_callback' => 'sanitize_text_field' 819 )); 820 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 821 $wp_customize,'motivational_speaker_comment_icon',array( 822 'label' => __('comment Icon','motivational-speaker'), 823 'transport' => 'refresh', 824 'section' => 'motivational_speaker_archieve_post_layot', 825 'setting' => 'motivational_speaker_comment_icon', 826 'type' => 'icon' 827 ))); 828 $wp_customize->add_setting('motivational_speaker_tag', 829 array( 830 'type' => 'option', 831 'capability' => 'edit_theme_options', 832 'theme_supports' => '', 833 'default' => '1', 834 'transport' => 'refresh', 835 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 836 ) 837 ); 838 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 839 $wp_customize, 840 'motivational_speaker_tag', 841 array( 842 'settings' => 'motivational_speaker_tag', 843 'section' => 'motivational_speaker_archieve_post_layot', 844 'label' => __( 'Show tag count', 'motivational-speaker' ), 845 'choices' => array( 846 '1' => __( 'On', 'motivational-speaker' ), 847 'off' => __( 'Off', 'motivational-speaker' ), 848 ), 849 'active_callback' => '', 850 ) 851 ) 852 ); 853 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_tag', array( 854 'selector' => '.tags', 855 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_tag', 856 ) ); 857 $wp_customize->add_setting('motivational_speaker_tag_icon',array( 858 'default' => 'fas fa-tags', 859 'sanitize_callback' => 'sanitize_text_field' 860 )); 861 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 862 $wp_customize,'motivational_speaker_tag_icon',array( 863 'label' => __('tag Icon','motivational-speaker'), 864 'transport' => 'refresh', 865 'section' => 'motivational_speaker_archieve_post_layot', 866 'setting' => 'motivational_speaker_tag_icon', 867 'type' => 'icon' 868 ))); 869 870 // breacrumb setting 354 871 $wp_customize->add_section('motivational_speaker_breadcrumb_settings',array( 355 'title' => __('Breadcrumb ', 'motivational-speaker'),356 'priority' => 2872 'title' => __('Breadcrumb Settings', 'motivational-speaker'), 873 'priority' => 4 357 874 ) ); 358 359 875 $wp_customize->add_setting( 'motivational_speaker_section_breadcrumb_heading', array( 360 876 'default' => '', … … 363 879 ) ); 364 880 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_breadcrumb_heading', array( 365 'label' => esc_html__( ' Breadcrumb Settings', 'motivational-speaker' ),881 'label' => esc_html__( 'Theme Breadcrumb Settings', 'motivational-speaker' ), 366 882 'section' => 'motivational_speaker_breadcrumb_settings', 367 883 'settings' => 'motivational_speaker_section_breadcrumb_heading', 368 884 ) ) ); 369 370 885 $wp_customize->add_setting( 371 886 'motivational_speaker_enable_breadcrumb', … … 395 910 ) 396 911 ); 397 if ( class_exists( 'WooCommerce' ) ) { 398 $wp_customize->add_section('motivational_speaker_woocommerce_settings',array( 399 'title' => __('WooCommerce Settings', 'motivational-speaker'), 400 'priority' => 2, 401 ) ); 402 403 $wp_customize->add_setting( 'motivational_speaker_section_shoppage_heading', array( 912 $wp_customize->add_setting( 'motivational_speaker_single_breadcrumb_heading', array( 404 913 'default' => '', 405 914 'transport' => 'refresh', 406 915 'sanitize_callback' => 'sanitize_text_field', 407 916 ) ); 408 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_s ection_shoppage_heading', array(409 'label' => esc_html__( 'S hop Page Settings', 'motivational-speaker' ),410 'section' => 'motivational_speaker_ woocommerce_settings',411 'settings' => 'motivational_speaker_s ection_shoppage_heading',917 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_single_breadcrumb_heading', array( 918 'label' => esc_html__( 'Single post & Page', 'motivational-speaker' ), 919 'section' => 'motivational_speaker_breadcrumb_settings', 920 'settings' => 'motivational_speaker_single_breadcrumb_heading', 412 921 ) ) ); 413 414 922 $wp_customize->add_setting( 415 'motivational_speaker_s hop_page_sidebar',923 'motivational_speaker_single_enable_breadcrumb', 416 924 array( 417 925 'type' => 'option', … … 426 934 new Motivational_Speaker_Customizer_Customcontrol_Switch( 427 935 $wp_customize, 428 'motivational_speaker_shop_page_sidebar', 429 array( 430 'settings' => 'motivational_speaker_shop_page_sidebar', 431 'section' => 'motivational_speaker_woocommerce_settings', 432 'label' => __( 'Show Shop Page Sidebar', 'motivational-speaker' ), 433 'choices' => array( 434 '1' => __( 'On', 'motivational-speaker' ), 435 'off' => __( 'Off', 'motivational-speaker' ), 436 ), 437 'active_callback' => '', 438 ) 439 ) 440 ); 441 442 $wp_customize->add_setting( 443 'motivational_speaker_wocommerce_single_page_sidebar', 444 array( 445 'type' => 'option', 446 'capability' => 'edit_theme_options', 447 'theme_supports' => '', 448 'default' => '1', 449 'transport' => 'refresh', 450 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 451 ) 452 ); 453 $wp_customize->add_control( 454 new Motivational_Speaker_Customizer_Customcontrol_Switch( 455 $wp_customize, 456 'motivational_speaker_wocommerce_single_page_sidebar', 457 array( 458 'settings' => 'motivational_speaker_wocommerce_single_page_sidebar', 459 'section' => 'motivational_speaker_woocommerce_settings', 460 'label' => __( 'Show Single Product Page Sidebar', 'motivational-speaker' ), 461 'choices' => array( 462 '1' => __( 'On', 'motivational-speaker' ), 463 'off' => __( 'Off', 'motivational-speaker' ), 464 ), 465 'active_callback' => '', 466 ) 467 ) 468 ); 469 $wp_customize->add_setting( 'motivational_speaker_section_archieve_product_heading', array( 470 'default' => '', 471 'transport' => 'refresh', 472 'sanitize_callback' => 'sanitize_text_field', 473 ) ); 474 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_archieve_product_heading', array( 475 'label' => esc_html__( 'Archieve Product Settings', 'motivational-speaker' ), 476 'section' => 'motivational_speaker_woocoomerce_settings', 477 'settings' => 'motivational_speaker_section_archieve_product_heading', 478 ) ) ); 479 480 $wp_customize->add_setting('motivational_speaker_archieve_item_columns',array( 481 'default' => '3', 482 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 483 )); 484 485 $wp_customize->add_control('motivational_speaker_archieve_item_columns',array( 486 'type' => 'select', 487 'label' => __('Select No of Columns','motivational-speaker'), 488 'section' => 'motivational_speaker_woocoomerce_settings', 489 'choices' => array( 490 '1' => __('One Column','motivational-speaker'), 491 '2' => __('Two Column','motivational-speaker'), 492 '3' => __('Three Column','motivational-speaker'), 493 '4' => __('four Column','motivational-speaker'), 494 '5' => __('Five Column','motivational-speaker'), 495 '6' => __('Six Column','motivational-speaker'), 496 ), 497 ) ); 498 499 $wp_customize->add_setting( 'motivational_speaker_archieve_shop_perpage', array( 500 'default' => 6, 501 'type' => 'theme_mod', 502 'transport' => 'refresh', 503 'sanitize_callback' => 'motivational_speaker_sanitize_number_absint', 504 'sanitize_js_callback' => 'absint', 505 ) ); 506 507 $wp_customize->add_control( 'motivational_speaker_archieve_shop_perpage', array( 508 'label' => esc_html__( 'Display Products','motivational-speaker' ), 509 'section' => 'motivational_speaker_woocoomerce_settings', 510 'type' => 'number', 511 'input_attrs' => array( 512 'step' => 1, 513 'min' => 0, 514 'max' => 30, 515 ), 516 ) ); 517 518 $wp_customize->add_setting( 'motivational_speaker_section_related_heading', array( 519 'default' => '', 520 'transport' => 'refresh', 521 'sanitize_callback' => 'sanitize_text_field', 522 ) ); 523 524 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_related_heading', array( 525 'label' => esc_html__( 'Related Product Settings', 'motivational-speaker' ), 526 'section' => 'motivational_speaker_woocoomerce_settings', 527 'settings' => 'motivational_speaker_section_related_heading', 528 ) ) ); 529 530 $wp_customize->add_setting('motivational_speaker_related_item_columns',array( 531 'default' => '3', 532 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 533 )); 534 535 $wp_customize->add_control('motivational_speaker_related_item_columns',array( 536 'type' => 'select', 537 'label' => __('Select No of Columns','motivational-speaker'), 538 'section' => 'motivational_speaker_woocoomerce_settings', 539 'choices' => array( 540 '1' => __('One Column','motivational-speaker'), 541 '2' => __('Two Column','motivational-speaker'), 542 '3' => __('Three Column','motivational-speaker'), 543 '4' => __('four Column','motivational-speaker'), 544 '5' => __('Five Column','motivational-speaker'), 545 '6' => __('Six Column','motivational-speaker'), 546 ), 547 ) ); 548 549 $wp_customize->add_setting( 'motivational_speaker_related_shop_perpage', array( 550 'default' => 3, 551 'type' => 'theme_mod', 552 'transport' => 'refresh', 553 'sanitize_callback' => 'motivational_speaker_sanitize_number_absint', 554 'sanitize_js_callback' => 'absint', 555 ) ); 556 557 $wp_customize->add_control( 'motivational_speaker_related_shop_perpage', array( 558 'label' => esc_html__( 'Display Products','motivational-speaker' ), 559 'section' => 'motivational_speaker_woocoomerce_settings', 560 'type' => 'number', 561 'input_attrs' => array( 562 'step' => 1, 563 'min' => 0, 564 'max' => 10, 565 ), 566 ) ); 567 568 $wp_customize->add_setting( 569 'motivational_speaker_related_product', 570 array( 571 'type' => 'option', 572 'capability' => 'edit_theme_options', 573 'theme_supports' => '', 574 'default' => '1', 575 'transport' => 'refresh', 576 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 577 ) 578 ); 579 580 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch($wp_customize,'motivational_speaker_related_product', 581 array( 582 'settings' => 'motivational_speaker_related_product', 583 'section' => 'motivational_speaker_woocoomerce_settings', 584 'label' => __( 'Show Related Products', 'motivational-speaker' ), 585 'choices' => array( 586 '1' => __( 'On', 'motivational-speaker' ), 587 'off' => __( 'Off', 'motivational-speaker' ), 588 ), 589 'active_callback' => '', 590 ) 591 )); 592 } 593 //theme width 594 $wp_customize->add_section('motivational_speaker_theme_width_settings',array( 595 'title' => __('Theme Width Option', 'motivational-speaker'), 596 'priority' => 2, 597 ) ); 598 599 $wp_customize->add_setting( 'motivational_speaker_theme_width_heading', array( 936 'motivational_speaker_single_enable_breadcrumb', 937 array( 938 'settings' => 'motivational_speaker_single_enable_breadcrumb', 939 'section' => 'motivational_speaker_breadcrumb_settings', 940 'label' => __( 'Show Breadcrumb', 'motivational-speaker' ), 941 'choices' => array( 942 '1' => __( 'On', 'motivational-speaker' ), 943 'off' => __( 'Off', 'motivational-speaker' ), 944 ), 945 'active_callback' => '', 946 ) 947 ) 948 ); 949 if ( class_exists( 'WooCommerce' ) ) { 950 $wp_customize->add_setting( 'motivational_speaker_woocommerce_breadcrumb_heading', array( 600 951 'default' => '', 601 952 'transport' => 'refresh', 602 953 'sanitize_callback' => 'sanitize_text_field', 603 954 ) ); 604 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_theme_width_heading', array( 605 'label' => esc_html__( 'Theme Width Settings', 'motivational-speaker' ), 606 'section' => 'motivational_speaker_theme_width_settings', 607 'settings' => 'motivational_speaker_theme_width_heading', 608 ) ) ); 609 610 $wp_customize->add_setting('motivational_speaker_width_options',array( 611 'default' => 'full_width', 612 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 613 )); 614 $wp_customize->add_control('motivational_speaker_width_options',array( 615 'type' => 'select', 616 'label' => __('Theme Width Option','motivational-speaker'), 617 'section' => 'motivational_speaker_theme_width_settings', 618 'choices' => array( 619 'full_width' => __('Fullwidth','motivational-speaker'), 620 'container' => __('Container','motivational-speaker'), 621 'container_fluid' => __('Container Fluid','motivational-speaker'), 622 ), 623 ) ); 624 //button 625 $wp_customize->add_section('motivational_speaker_button_options',array( 626 'title' => __('Button settings', 'motivational-speaker'), 627 'priority' => 2, 628 ) ); 629 630 $wp_customize->add_setting( 'motivational_speaker_theme_button_heading', array( 955 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_woocommerce_breadcrumb_heading', array( 956 'label' => esc_html__( 'Woocommerce Breadcrumb', 'motivational-speaker' ), 957 'section' => 'motivational_speaker_breadcrumb_settings', 958 'settings' => 'motivational_speaker_woocommerce_breadcrumb_heading', 959 ) ) ); 960 $wp_customize->add_setting( 961 'motivational_speaker_woocommerce_enable_breadcrumb', 962 array( 963 'type' => 'option', 964 'capability' => 'edit_theme_options', 965 'theme_supports' => '', 966 'default' => '1', 967 'transport' => 'refresh', 968 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 969 ) 970 ); 971 $wp_customize->add_control( 972 new Motivational_Speaker_Customizer_Customcontrol_Switch( 973 $wp_customize, 974 'motivational_speaker_woocommerce_enable_breadcrumb', 975 array( 976 'settings' => 'motivational_speaker_woocommerce_enable_breadcrumb', 977 'section' => 'motivational_speaker_breadcrumb_settings', 978 'label' => __( 'Show Breadcrumb', 'motivational-speaker' ), 979 'choices' => array( 980 '1' => __( 'On', 'motivational-speaker' ), 981 'off' => __( 'Off', 'motivational-speaker' ), 982 ), 983 'active_callback' => '', 984 ) 985 ) 986 ); 987 } 988 989 // woocommerce 990 if ( class_exists( 'WooCommerce' ) ) { 991 $wp_customize->add_section('motivational_speaker_woocommerce_settings',array( 992 'title' => __('WooCommerce Settings', 'motivational-speaker'), 993 'priority' => 4, 994 ) ); 995 $wp_customize->add_setting( 'motivational_speaker_section_shoppage_heading', array( 631 996 'default' => '', 632 997 'transport' => 'refresh', 633 998 'sanitize_callback' => 'sanitize_text_field', 634 999 ) ); 1000 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_shoppage_heading', array( 1001 'label' => esc_html__( 'Shop Page Settings', 'motivational-speaker' ), 1002 'section' => 'motivational_speaker_woocommerce_settings', 1003 'settings' => 'motivational_speaker_section_shoppage_heading', 1004 ) ) ); 1005 $wp_customize->add_setting( 1006 'motivational_speaker_shop_page_sidebar', 1007 array( 1008 'type' => 'option', 1009 'capability' => 'edit_theme_options', 1010 'theme_supports' => '', 1011 'default' => '1', 1012 'transport' => 'refresh', 1013 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1014 ) 1015 ); 1016 $wp_customize->add_control( 1017 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1018 $wp_customize, 1019 'motivational_speaker_shop_page_sidebar', 1020 array( 1021 'settings' => 'motivational_speaker_shop_page_sidebar', 1022 'section' => 'motivational_speaker_woocommerce_settings', 1023 'label' => __( 'Show Shop Page Sidebar', 'motivational-speaker' ), 1024 'choices' => array( 1025 '1' => __( 'On', 'motivational-speaker' ), 1026 'off' => __( 'Off', 'motivational-speaker' ), 1027 ), 1028 'active_callback' => '', 1029 ) 1030 ) 1031 ); 1032 $wp_customize->add_setting( 1033 'motivational_speaker_wocommerce_single_page_sidebar', 1034 array( 1035 'type' => 'option', 1036 'capability' => 'edit_theme_options', 1037 'theme_supports' => '', 1038 'default' => '1', 1039 'transport' => 'refresh', 1040 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1041 ) 1042 ); 1043 $wp_customize->add_control( 1044 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1045 $wp_customize, 1046 'motivational_speaker_wocommerce_single_page_sidebar', 1047 array( 1048 'settings' => 'motivational_speaker_wocommerce_single_page_sidebar', 1049 'section' => 'motivational_speaker_woocommerce_settings', 1050 'label' => __( 'Show Single Product Page Sidebar', 'motivational-speaker' ), 1051 'choices' => array( 1052 '1' => __( 'On', 'motivational-speaker' ), 1053 'off' => __( 'Off', 'motivational-speaker' ), 1054 ), 1055 'active_callback' => '', 1056 ) 1057 ) 1058 ); 1059 $wp_customize->add_setting( 'motivational_speaker_section_archieve_product_heading', array( 1060 'default' => '', 1061 'transport' => 'refresh', 1062 'sanitize_callback' => 'sanitize_text_field', 1063 ) ); 1064 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_archieve_product_heading', array( 1065 'label' => esc_html__( 'Archieve Product Settings', 'motivational-speaker' ), 1066 'section' => 'motivational_speaker_woocoomerce_settings', 1067 'settings' => 'motivational_speaker_section_archieve_product_heading', 1068 ) ) ); 1069 $wp_customize->add_setting('motivational_speaker_archieve_item_columns',array( 1070 'default' => '3', 1071 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 1072 )); 1073 $wp_customize->add_control('motivational_speaker_archieve_item_columns',array( 1074 'type' => 'select', 1075 'label' => __('Select No of Columns','motivational-speaker'), 1076 'section' => 'motivational_speaker_woocoomerce_settings', 1077 'choices' => array( 1078 '1' => __('One Column','motivational-speaker'), 1079 '2' => __('Two Column','motivational-speaker'), 1080 '3' => __('Three Column','motivational-speaker'), 1081 '4' => __('four Column','motivational-speaker'), 1082 '5' => __('Five Column','motivational-speaker'), 1083 '6' => __('Six Column','motivational-speaker'), 1084 ), 1085 ) ); 1086 $wp_customize->add_setting( 'motivational_speaker_archieve_shop_perpage', array( 1087 'default' => 6, 1088 'type' => 'theme_mod', 1089 'transport' => 'refresh', 1090 'sanitize_callback' => 'motivational_speaker_sanitize_number_absint', 1091 'sanitize_js_callback' => 'absint', 1092 ) ); 1093 $wp_customize->add_control( 'motivational_speaker_archieve_shop_perpage', array( 1094 'label' => esc_html__( 'Display Products','motivational-speaker' ), 1095 'section' => 'motivational_speaker_woocoomerce_settings', 1096 'type' => 'number', 1097 'input_attrs' => array( 1098 'step' => 1, 1099 'min' => 0, 1100 'max' => 30, 1101 ), 1102 ) ); 1103 $wp_customize->add_setting( 'motivational_speaker_section_related_heading', array( 1104 'default' => '', 1105 'transport' => 'refresh', 1106 'sanitize_callback' => 'sanitize_text_field', 1107 ) ); 1108 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_related_heading', array( 1109 'label' => esc_html__( 'Related Product Settings', 'motivational-speaker' ), 1110 'section' => 'motivational_speaker_woocoomerce_settings', 1111 'settings' => 'motivational_speaker_section_related_heading', 1112 ) ) ); 1113 $wp_customize->add_setting('motivational_speaker_related_item_columns',array( 1114 'default' => '3', 1115 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 1116 )); 1117 $wp_customize->add_control('motivational_speaker_related_item_columns',array( 1118 'type' => 'select', 1119 'label' => __('Select No of Columns','motivational-speaker'), 1120 'section' => 'motivational_speaker_woocoomerce_settings', 1121 'choices' => array( 1122 '1' => __('One Column','motivational-speaker'), 1123 '2' => __('Two Column','motivational-speaker'), 1124 '3' => __('Three Column','motivational-speaker'), 1125 '4' => __('four Column','motivational-speaker'), 1126 '5' => __('Five Column','motivational-speaker'), 1127 '6' => __('Six Column','motivational-speaker'), 1128 ), 1129 ) ); 1130 $wp_customize->add_setting( 'motivational_speaker_related_shop_perpage', array( 1131 'default' => 3, 1132 'type' => 'theme_mod', 1133 'transport' => 'refresh', 1134 'sanitize_callback' => 'motivational_speaker_sanitize_number_absint', 1135 'sanitize_js_callback' => 'absint', 1136 ) ); 1137 $wp_customize->add_control( 'motivational_speaker_related_shop_perpage', array( 1138 'label' => esc_html__( 'Display Products','motivational-speaker' ), 1139 'section' => 'motivational_speaker_woocoomerce_settings', 1140 'type' => 'number', 1141 'input_attrs' => array( 1142 'step' => 1, 1143 'min' => 0, 1144 'max' => 10, 1145 ), 1146 ) ); 1147 $wp_customize->add_setting( 1148 'motivational_speaker_related_product', 1149 array( 1150 'type' => 'option', 1151 'capability' => 'edit_theme_options', 1152 'theme_supports' => '', 1153 'default' => '1', 1154 'transport' => 'refresh', 1155 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1156 ) 1157 ); 1158 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch($wp_customize,'motivational_speaker_related_product', 1159 array( 1160 'settings' => 'motivational_speaker_related_product', 1161 'section' => 'motivational_speaker_woocoomerce_settings', 1162 'label' => __( 'Show Related Products', 'motivational-speaker' ), 1163 'choices' => array( 1164 '1' => __( 'On', 'motivational-speaker' ), 1165 'off' => __( 'Off', 'motivational-speaker' ), 1166 ), 1167 'active_callback' => '', 1168 ) 1169 )); 1170 } 1171 1172 //button 1173 $wp_customize->add_section('motivational_speaker_button_options',array( 1174 'title' => __('Button settings', 'motivational-speaker'), 1175 'priority' => 4, 1176 ) ); 1177 $wp_customize->add_setting( 'motivational_speaker_theme_button_heading', array( 1178 'default' => '', 1179 'transport' => 'refresh', 1180 'sanitize_callback' => 'sanitize_text_field', 1181 ) ); 635 1182 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_theme_button_heading', array( 636 1183 'label' => esc_html__( 'Theme Button Settings', 'motivational-speaker' ), … … 638 1185 'settings' => 'motivational_speaker_theme_button_heading', 639 1186 ) ) ); 640 641 1187 $wp_customize->add_setting( 'motivational_speaker_theme_button_color', array( 642 1188 'default' => '', … … 648 1194 'settings' => 'motivational_speaker_theme_button_color', 649 1195 ))); 650 651 1196 $wp_customize->add_setting('motivational_speaker_button_border_radius',array( 652 1197 'default'=> 8, … … 665 1210 ), 666 1211 ))); 667 // Post Layouts 668 $wp_customize->add_section('motivational_speaker_layout',array( 669 'title' => __('Post Layout', 'motivational-speaker'), 670 'priority' => 2, 671 ) ); 672 673 $wp_customize->add_setting( 'motivational_speaker_section_post_heading', array( 674 'default' => '', 675 'transport' => 'refresh', 676 'sanitize_callback' => 'sanitize_text_field', 677 ) ); 678 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_post_heading', array( 679 'label' => esc_html__( 'single Post Structure', 'motivational-speaker' ), 680 'description' => __( 'Change the post layout from below options', 'motivational-speaker' ), 681 'section' => 'motivational_speaker_layout', 682 'settings' => 'motivational_speaker_section_post_heading', 683 ) ) ); 684 685 $wp_customize->add_setting( 'motivational_speaker_single_post_option', 686 array( 687 'default' => 'single_right_sidebar', 688 'transport' => 'refresh', 689 'sanitize_callback' => 'sanitize_text_field' 690 ) 691 ); 692 693 $wp_customize->add_control( new Motivational_Speaker_Radio_Image_Control( $wp_customize, 'motivational_speaker_single_post_option', 694 array( 695 'type'=>'select', 696 'label' => __( 'select Single Post Page Layout', 'motivational-speaker' ), 697 'section' => 'motivational_speaker_layout', 698 'choices' => array( 699 700 'single_right_sidebar' => array( 701 'image' => get_template_directory_uri().'/assets/images/2column.jpg', 702 'name' => __( 'Right Sidebar', 'motivational-speaker' ) 703 ), 704 'single_left_sidebar' => array( 705 'image' => get_template_directory_uri().'/assets/images/left.png', 706 'name' => __( 'Left Sidebar', 'motivational-speaker' ) 707 ), 708 'single_full_width' => array( 709 'image' => get_template_directory_uri().'/assets/images/1column.jpg', 710 'name' => __( 'One Column', 'motivational-speaker' ) 711 ), 712 ) 713 ) 714 ) ); 715 716 717 $wp_customize->add_setting('motivational_speaker_single_post_date', 718 array( 719 'type' => 'option', 720 'capability' => 'edit_theme_options', 721 'theme_supports' => '', 722 'default' => '1', 723 'transport' => 'refresh', 724 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 725 ) 726 ); 727 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 728 $wp_customize, 729 'motivational_speaker_single_post_date', 730 array( 731 'settings' => 'motivational_speaker_single_post_date', 732 'section' => 'motivational_speaker_layout', 733 'label' => __( 'Show Date', 'motivational-speaker' ), 734 'choices' => array( 735 '1' => __( 'On', 'motivational-speaker' ), 736 'off' => __( 'Off', 'motivational-speaker' ), 737 ), 738 'active_callback' => '', 739 ) 740 ) 741 ); 742 743 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_single_post_date', array( 744 'selector' => '.date-box', 745 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_single_post_date', 746 ) ); 747 748 $wp_customize->add_setting('motivational_speaker_single_post_admin', 749 array( 750 'type' => 'option', 751 'capability' => 'edit_theme_options', 752 'theme_supports' => '', 753 'default' => '1', 754 'transport' => 'refresh', 755 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 756 ) 757 ); 758 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 759 $wp_customize, 760 'motivational_speaker_single_post_admin', 761 array( 762 'settings' => 'motivational_speaker_single_post_admin', 763 'section' => 'motivational_speaker_layout', 764 'label' => __( 'Show Author/Admin', 'motivational-speaker' ), 765 'choices' => array( 766 '1' => __( 'On', 'motivational-speaker' ), 767 'off' => __( 'Off', 'motivational-speaker' ), 768 ), 769 'active_callback' => '', 770 ) 771 ) 772 ); 773 774 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_single_post_admin', array( 775 'selector' => '.entry-author', 776 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_single_post_admin', 777 ) ); 778 779 $wp_customize->add_setting('motivational_speaker_single_post_comment', 780 array( 781 'type' => 'option', 782 'capability' => 'edit_theme_options', 783 'theme_supports' => '', 784 'default' => '1', 785 'transport' => 'refresh', 786 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 787 ) 788 ); 789 $wp_customize->add_control(new motivational_speaker_Customizer_Customcontrol_Switch( 790 $wp_customize, 791 'motivational_speaker_single_post_comment', 792 array( 793 'settings' => 'motivational_speaker_single_post_comment', 794 'section' => 'motivational_speaker_layout', 795 'label' => __( 'Show Comment', 'motivational-speaker' ), 796 'choices' => array( 797 '1' => __( 'On', 'motivational-speaker' ), 798 'off' => __( 'Off', 'motivational-speaker' ), 799 ), 800 'active_callback' => '', 801 ) 802 ) 803 ); 804 805 $wp_customize->add_setting( 'motivational_speaker_section_archive_post_heading', array( 806 'default' => '', 807 'transport' => 'refresh', 808 'sanitize_callback' => 'sanitize_text_field', 809 ) ); 810 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_archive_post_heading', array( 811 'label' => esc_html__( 'Archieve Post Structure', 'motivational-speaker' ), 812 'description' => __( 'Change the post layout from below options', 'motivational-speaker' ), 813 'section' => 'motivational_speaker_layout', 814 'settings' => 'motivational_speaker_section_archive_post_heading', 815 ) ) ); 816 817 $wp_customize->add_setting( 'motivational_speaker_post_option', 818 array( 819 'default' => 'right_sidebar', 820 'transport' => 'refresh', 821 'sanitize_callback' => 'sanitize_text_field' 822 ) 823 ); 824 $wp_customize->add_control( new Motivational_Speaker_Radio_Image_Control( $wp_customize, 'motivational_speaker_post_option', 825 array( 826 'type'=>'select', 827 'label' => __( 'select Post Page Layout', 'motivational-speaker' ), 828 'section' => 'motivational_speaker_layout', 829 'choices' => array( 830 'right_sidebar' => array( 831 'image' => get_template_directory_uri().'/assets/images/2column.jpg', 832 'name' => __( 'Right Sidebar', 'motivational-speaker' ) 833 ), 834 'left_sidebar' => array( 835 'image' => get_template_directory_uri().'/assets/images/left.png', 836 'name' => __( 'Left Sidebar', 'motivational-speaker' ) 837 ), 838 'one_column' => array( 839 'image' => get_template_directory_uri().'/assets/images/1column.jpg', 840 'name' => __( 'One Column', 'motivational-speaker' ) 841 ), 842 'three_column' => array( 843 'image' => get_template_directory_uri().'/assets/images/3column.jpg', 844 'name' => __( 'Three Column', 'motivational-speaker' ) 845 ), 846 'four_column' => array( 847 'image' => get_template_directory_uri().'/assets/images/4column.jpg', 848 'name' => __( 'Four Column', 'motivational-speaker' ) 849 ), 850 'grid_sidebar' => array( 851 'image' => get_template_directory_uri().'/assets/images/grid-sidebar.jpg', 852 'name' => __( 'Grid-Sidebar Layout', 'motivational-speaker' ) 853 ), 854 'grid_left_sidebar' => array( 855 'image' => get_template_directory_uri().'/assets/images/grid-left.png', 856 'name' => __( 'Grid-Left-Sidebar Layout', 'motivational-speaker' ) 857 ), 858 'grid_post' => array( 859 'image' => get_template_directory_uri().'/assets/images/grid.jpg', 860 'name' => __( 'Grid Layout', 'motivational-speaker' ) 861 ) 862 ) 863 ) 864 ) ); 865 866 $wp_customize->add_setting('motivational_speaker_grid_column',array( 867 'default' => '3_column', 868 'sanitize_callback' => 'motivational_speaker_sanitize_select' 869 )); 870 $wp_customize->add_control('motivational_speaker_grid_column',array( 871 'label' => esc_html__('Grid Post Per Row','motivational-speaker'), 872 'section' => 'motivational_speaker_layout', 873 'setting' => 'motivational_speaker_grid_column', 874 'type' => 'radio', 875 'choices' => array( 876 '1_column' => __('1','motivational-speaker'), 877 '2_column' => __('2','motivational-speaker'), 878 '3_column' => __('3','motivational-speaker'), 879 '4_column' => __('4','motivational-speaker'), 880 '5_column' => __('6','motivational-speaker'), 881 ), 882 )); 883 884 $wp_customize->add_setting('motivational_speaker_date', 885 array( 886 'type' => 'option', 887 'capability' => 'edit_theme_options', 888 'theme_supports' => '', 889 'default' => '1', 890 'transport' => 'refresh', 891 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 892 ) 893 ); 894 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 895 $wp_customize, 896 'motivational_speaker_date', 897 array( 898 'settings' => 'motivational_speaker_date', 899 'section' => 'motivational_speaker_layout', 900 'label' => __( 'show Date', 'motivational-speaker' ), 901 'choices' => array( 902 '1' => __( 'On', 'motivational-speaker' ), 903 'off' => __( 'Off', 'motivational-speaker' ), 904 ), 905 'active_callback' => '', 906 ) 907 ) 908 ); 909 910 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_date', array( 911 'selector' => '.date-box', 912 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_date', 913 ) ); 914 915 $wp_customize->add_setting('motivational_speaker_admin', 916 array( 917 'type' => 'option', 918 'capability' => 'edit_theme_options', 919 'theme_supports' => '', 920 'default' => '1', 921 'transport' => 'refresh', 922 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 923 ) 924 ); 925 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 926 $wp_customize, 927 'motivational_speaker_admin', 928 array( 929 'settings' => 'motivational_speaker_admin', 930 'section' => 'motivational_speaker_layout', 931 'label' => __( 'show Author/Admin', 'motivational-speaker' ), 932 'choices' => array( 933 '1' => __( 'On', 'motivational-speaker' ), 934 'off' => __( 'Off', 'motivational-speaker' ), 935 ), 936 'active_callback' => '', 937 ) 938 ) 939 ); 940 941 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_admin', array( 942 'selector' => '.entry-author', 943 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_admin', 944 ) ); 945 946 $wp_customize->add_setting('motivational_speaker_comment', 947 array( 948 'type' => 'option', 949 'capability' => 'edit_theme_options', 950 'theme_supports' => '', 951 'default' => '1', 952 'transport' => 'refresh', 953 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 954 ) 955 ); 956 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 957 $wp_customize, 958 'motivational_speaker_comment', 959 array( 960 'settings' => 'motivational_speaker_comment', 961 'section' => 'motivational_speaker_layout', 962 'label' => __( 'show Comment', 'motivational-speaker' ), 963 'choices' => array( 964 '1' => __( 'On', 'motivational-speaker' ), 965 'off' => __( 'Off', 'motivational-speaker' ), 966 ), 967 'active_callback' => '', 968 ) 969 ) 970 ); 971 972 $wp_customize->selective_refresh->add_partial( 'motivational_speaker_comment', array( 973 'selector' => '.entry-comments', 974 'render_callback' => 'motivational_speaker_customize_partial_motivational_speaker_comment', 975 ) ); 976 977 // Top Header 978 $wp_customize->add_section('motivational_speaker_top',array( 979 'title' => __('Header Settings', 'motivational-speaker'), 980 'priority' => 3 981 ) ); 982 983 $wp_customize->add_setting( 'motivational_speaker_section_contact_heading', array( 984 'default' => '', 985 'transport' => 'refresh', 986 'sanitize_callback' => 'sanitize_text_field', 987 ) ); 988 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_contact_heading', array( 989 'label' => esc_html__( 'Contact Settings', 'motivational-speaker' ), 990 'section' => 'motivational_speaker_top', 991 'settings' => 'motivational_speaker_section_contact_heading', 992 ) ) ); 993 994 $wp_customize->add_setting( 995 'motivational_speaker_search_enable', 996 array( 997 'type' => 'option', 998 'capability' => 'edit_theme_options', 999 'theme_supports' => '', 1000 'default' => '1', 1001 'transport' => 'refresh', 1002 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1003 ) 1004 ); 1005 $wp_customize->add_control( 1006 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1007 $wp_customize, 1008 'motivational_speaker_search_enable', 1009 array( 1010 'settings' => 'motivational_speaker_search_enable', 1011 'section' => 'motivational_speaker_top', 1012 'label' => __( 'Check to show search bar', 'motivational-speaker' ), 1013 'choices' => array( 1014 '1' => __( 'On', 'motivational-speaker' ), 1015 'off' => __( 'Off', 'motivational-speaker' ), 1016 ), 1017 'active_callback' => '', 1018 ) 1019 ) 1020 ); 1021 1022 $wp_customize->add_setting('motivational_speaker_call_text',array( 1023 'default' => '', 1024 'sanitize_callback' => 'sanitize_text_field' 1025 )); 1026 $wp_customize->add_control('motivational_speaker_call_text',array( 1027 'label' => esc_html__('Add Phone Text','motivational-speaker'), 1028 'section' => 'motivational_speaker_top', 1029 'setting' => 'motivational_speaker_call_text', 1030 'type' => 'text' 1031 )); 1032 1033 $wp_customize->add_setting('motivational_speaker_call_number',array( 1034 'default' => '', 1035 'sanitize_callback' => 'motivational_speaker_sanitize_phone_number' 1036 )); 1037 $wp_customize->add_control('motivational_speaker_call_number',array( 1038 'label' => esc_html__('Add Phone Number','motivational-speaker'), 1039 'section' => 'motivational_speaker_top', 1040 'setting' => 'motivational_speaker_call_number', 1041 'type' => 'text' 1042 )); 1043 1044 $wp_customize->add_setting('motivational_speaker_call_icon',array( 1045 'default' => 'fas fa-phone', 1046 'sanitize_callback' => 'sanitize_text_field' 1047 )); 1048 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 1049 $wp_customize,'motivational_speaker_call_icon',array( 1050 'label' => __('Add call Icon','motivational-speaker'), 1051 'transport' => 'refresh', 1052 'section' => 'motivational_speaker_top', 1053 'setting' => 'motivational_speaker_call_icon', 1054 'type' => 'icon' 1055 ))); 1056 1057 $wp_customize->add_setting('motivational_speaker_email_address_text',array( 1058 'default' => '', 1059 'sanitize_callback' => 'sanitize_text_field' 1060 )); 1061 $wp_customize->add_control('motivational_speaker_email_address_text',array( 1062 'label' => esc_html__('Add Email Text','motivational-speaker'), 1063 'section' => 'motivational_speaker_top', 1064 'setting' => 'motivational_speaker_email_address_text', 1065 'type' => 'text' 1066 )); 1067 1068 $wp_customize->add_setting('motivational_speaker_email_address',array( 1069 'default' => '', 1070 'sanitize_callback' => 'sanitize_email' 1071 )); 1072 $wp_customize->add_control('motivational_speaker_email_address',array( 1073 'label' => esc_html__('Add Email Address','motivational-speaker'), 1074 'section' => 'motivational_speaker_top', 1075 'setting' => 'motivational_speaker_email_address', 1076 'type' => 'text' 1077 )); 1078 1079 $wp_customize->add_setting('motivational_speaker_email_icon',array( 1080 'default' => 'fas fa-envelope', 1081 'sanitize_callback' => 'sanitize_text_field' 1082 )); 1083 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 1084 $wp_customize,'motivational_speaker_email_icon',array( 1085 'label' => __('Add email Icon','motivational-speaker'), 1086 'transport' => 'refresh', 1087 'section' => 'motivational_speaker_top', 1088 'setting' => 'motivational_speaker_email_icon', 1089 'type' => 'icon' 1090 ))); 1091 1092 // Social Media 1093 $wp_customize->add_section('motivational_speaker_social_media',array( 1094 'title' => __('Social Media', 'motivational-speaker'), 1095 'priority' => 3 1096 ) ); 1097 1098 $wp_customize->add_setting( 'motivational_speaker_section_social_heading', array( 1099 'default' => '', 1100 'transport' => 'refresh', 1101 'sanitize_callback' => 'sanitize_text_field', 1102 ) ); 1103 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_social_heading', array( 1104 'label' => esc_html__( 'Social Media Settings', 'motivational-speaker' ), 1105 'description' => __( 'Add social media links in the below feilds', 'motivational-speaker' ), 1106 'section' => 'motivational_speaker_social_media', 1107 'settings' => 'motivational_speaker_section_social_heading', 1108 ) ) ); 1109 1110 $wp_customize->add_setting( 1111 'motivational_speaker_social_enable', 1112 array( 1113 'type' => 'option', 1114 'capability' => 'edit_theme_options', 1115 'theme_supports' => '', 1116 'default' => '1', 1117 'transport' => 'refresh', 1118 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1119 ) 1120 ); 1121 $wp_customize->add_control( 1122 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1123 $wp_customize, 1124 'motivational_speaker_social_enable', 1125 array( 1126 'settings' => 'motivational_speaker_social_enable', 1127 'section' => 'motivational_speaker_social_media', 1128 'label' => __( 'Check to show social fields', 'motivational-speaker' ), 1129 'choices' => array( 1130 '1' => __( 'On', 'motivational-speaker' ), 1131 'off' => __( 'Off', 'motivational-speaker' ), 1132 ), 1133 'active_callback' => '', 1134 ) 1135 ) 1136 ); 1137 $wp_customize->add_setting( 'motivational_speaker_twitter_heading', array( 1138 'default' => '', 1139 'transport' => 'refresh', 1140 'sanitize_callback' => 'sanitize_text_field', 1141 ) ); 1142 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_twitter_heading', array( 1143 'label' => esc_html__( 'Twitter Settings', 'motivational-speaker' ), 1144 'section' => 'motivational_speaker_social_media', 1145 'settings' => 'motivational_speaker_twitter_heading', 1146 ) ) ); 1147 $wp_customize->add_setting('motivational_speaker_twitter_icon',array( 1148 'default' => 'fab fa-twitter', 1149 'sanitize_callback' => 'sanitize_text_field' 1150 )); 1151 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 1152 $wp_customize,'motivational_speaker_twitter_icon',array( 1153 'label' => __('Add Icon','motivational-speaker'), 1154 'transport' => 'refresh', 1155 'section' => 'motivational_speaker_social_media', 1156 'setting' => 'motivational_speaker_twitter_icon', 1157 'type' => 'icon' 1158 ))); 1159 1160 $wp_customize->add_setting('motivational_speaker_twitter',array( 1161 'default' => '', 1162 'sanitize_callback' => 'esc_url_raw' 1163 )); 1164 $wp_customize->add_control('motivational_speaker_twitter',array( 1165 'label' => esc_html__('Add URL','motivational-speaker'), 1166 'section' => 'motivational_speaker_social_media', 1167 'setting' => 'motivational_speaker_twitter', 1168 'type' => 'url' 1169 )); 1170 1171 $wp_customize->add_setting( 1172 'motivational_speaker_header_twt_target', 1173 array( 1174 'type' => 'option', 1175 'capability' => 'edit_theme_options', 1176 'theme_supports' => '', 1177 'default' => '1', 1178 'transport' => 'refresh', 1179 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1180 ) 1181 ); 1182 $wp_customize->add_control( 1183 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1184 $wp_customize, 1185 'motivational_speaker_header_twt_target', 1186 array( 1187 'settings' => 'motivational_speaker_header_twt_target', 1188 'section' => 'motivational_speaker_social_media', 1189 'label' => __( 'Open link in a new tab', 'motivational-speaker' ), 1190 'choices' => array( 1191 '1' => __( 'On', 'motivational-speaker' ), 1192 'off' => __( 'Off', 'motivational-speaker' ), 1193 ), 1194 'active_callback' => '', 1195 ) 1196 ) 1197 ); 1198 $wp_customize->add_setting( 'motivational_speaker_fb_heading', array( 1199 'default' => '', 1200 'transport' => 'refresh', 1201 'sanitize_callback' => 'sanitize_text_field', 1202 ) ); 1203 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_fb_heading', array( 1204 'label' => esc_html__( ' Facebook Settings', 'motivational-speaker' ), 1205 'section' => 'motivational_speaker_social_media', 1206 'settings' => 'motivational_speaker_fb_heading', 1207 ) ) ); 1208 $wp_customize->add_setting('motivational_speaker_fb_icon',array( 1209 'default' => 'fab fa-facebook-f', 1210 'sanitize_callback' => 'sanitize_text_field' 1211 )); 1212 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 1213 $wp_customize,'motivational_speaker_fb_icon',array( 1214 'label' => __('Add Icon','motivational-speaker'), 1215 'transport' => 'refresh', 1216 'section' => 'motivational_speaker_social_media', 1217 'setting' => 'motivational_speaker_fb_icon', 1218 'type' => 'icon' 1219 ))); 1220 1221 $wp_customize->add_setting('motivational_speaker_facebook',array( 1222 'default' => '', 1223 'sanitize_callback' => 'esc_url_raw' 1224 )); 1225 $wp_customize->add_control('motivational_speaker_facebook',array( 1226 'label' => esc_html__('Add URL','motivational-speaker'), 1227 'section' => 'motivational_speaker_social_media', 1228 'setting' => 'motivational_speaker_facebook', 1229 'type' => 'url' 1230 )); 1231 1232 $wp_customize->add_setting( 1233 'motivational_speaker_header_fb_target', 1234 array( 1235 'type' => 'option', 1236 'capability' => 'edit_theme_options', 1237 'theme_supports' => '', 1238 'default' => '1', 1239 'transport' => 'refresh', 1240 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1241 ) 1242 ); 1243 $wp_customize->add_control( 1244 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1245 $wp_customize, 1246 'motivational_speaker_header_fb_target', 1247 array( 1248 'settings' => 'motivational_speaker_header_fb_target', 1249 'section' => 'motivational_speaker_social_media', 1250 'label' => __( 'Open link in a new tab', 'motivational-speaker' ), 1251 'choices' => array( 1252 '1' => __( 'On', 'motivational-speaker' ), 1253 'off' => __( 'Off', 'motivational-speaker' ), 1254 ), 1255 'active_callback' => '', 1256 ) 1257 ) 1258 ); 1259 $wp_customize->add_setting( 'motivational_speaker_youtube_heading', array( 1260 'default' => '', 1261 'transport' => 'refresh', 1262 'sanitize_callback' => 'sanitize_text_field', 1263 ) ); 1264 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_youtube_heading', array( 1265 'label' => esc_html__( ' Youtube Settings', 'motivational-speaker' ), 1266 'section' => 'motivational_speaker_social_media', 1267 'settings' => 'motivational_speaker_youtube_heading', 1268 ) ) ); 1269 $wp_customize->add_setting('motivational_speaker_youtube_icon',array( 1270 'default' => 'fab fa-youtube', 1271 'sanitize_callback' => 'sanitize_text_field' 1272 )); 1273 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 1274 $wp_customize,'motivational_speaker_youtube_icon',array( 1275 'label' => __('Add Icon','motivational-speaker'), 1276 'transport' => 'refresh', 1277 'section' => 'motivational_speaker_social_media', 1278 'setting' => 'motivational_speaker_youtube_icon', 1279 'type' => 'icon' 1280 ))); 1281 1282 $wp_customize->add_setting('motivational_speaker_youtube',array( 1283 'default' => '', 1284 'sanitize_callback' => 'esc_url_raw' 1285 )); 1286 $wp_customize->add_control('motivational_speaker_youtube',array( 1287 'label' => esc_html__('Add URL','motivational-speaker'), 1288 'section' => 'motivational_speaker_social_media', 1289 'setting' => 'motivational_speaker_youtube', 1290 'type' => 'url' 1291 )); 1292 1293 $wp_customize->add_setting( 1294 'motivational_speaker_header_youtube_target', 1295 array( 1296 'type' => 'option', 1297 'capability' => 'edit_theme_options', 1298 'theme_supports' => '', 1299 'default' => '1', 1300 'transport' => 'refresh', 1301 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1302 ) 1303 ); 1304 $wp_customize->add_control( 1305 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1306 $wp_customize, 1307 'motivational_speaker_header_youtube_target', 1308 array( 1309 'settings' => 'motivational_speaker_header_youtube_target', 1310 'section' => 'motivational_speaker_social_media', 1311 'label' => __( 'Open link in a new tab', 'motivational-speaker' ), 1312 'choices' => array( 1313 '1' => __( 'On', 'motivational-speaker' ), 1314 'off' => __( 'Off', 'motivational-speaker' ), 1315 ), 1316 'active_callback' => '', 1317 ) 1318 ) 1319 ); 1320 $wp_customize->add_setting( 'motivational_speaker_instagram_heading', array( 1321 'default' => '', 1322 'transport' => 'refresh', 1323 'sanitize_callback' => 'sanitize_text_field', 1324 ) ); 1325 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_instagram_heading', array( 1326 'label' => esc_html__( ' Instagram Settings', 'motivational-speaker' ), 1327 'section' => 'motivational_speaker_social_media', 1328 'settings' => 'motivational_speaker_instagram_heading', 1329 ) ) ); 1330 $wp_customize->add_setting('motivational_speaker_instagram_icon',array( 1331 'default' => 'fab fa-instagram', 1332 'sanitize_callback' => 'sanitize_text_field' 1333 )); 1334 $wp_customize->add_control(new Motivational_Speaker_Fontawesome_Icon_Chooser( 1335 $wp_customize,'motivational_speaker_instagram_icon',array( 1336 'label' => __('Add Icon','motivational-speaker'), 1337 'transport' => 'refresh', 1338 'section' => 'motivational_speaker_social_media', 1339 'setting' => 'motivational_speaker_instagram_icon', 1340 'type' => 'icon' 1341 ))); 1342 1343 $wp_customize->add_setting('motivational_speaker_instagram',array( 1344 'default' => '', 1345 'sanitize_callback' => 'esc_url_raw' 1346 )); 1347 $wp_customize->add_control('motivational_speaker_instagram',array( 1348 'label' => esc_html__('Add URL','motivational-speaker'), 1349 'section' => 'motivational_speaker_social_media', 1350 'setting' => 'motivational_speaker_instagram', 1351 'type' => 'url' 1352 )); 1353 1354 $wp_customize->add_setting( 1355 'motivational_speaker_header_instagram_target', 1356 array( 1357 'type' => 'option', 1358 'capability' => 'edit_theme_options', 1359 'theme_supports' => '', 1360 'default' => '1', 1361 'transport' => 'refresh', 1362 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1363 ) 1364 ); 1365 $wp_customize->add_control( 1366 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1367 $wp_customize, 1368 'motivational_speaker_header_instagram_target', 1369 array( 1370 'settings' => 'motivational_speaker_header_instagram_target', 1371 'section' => 'motivational_speaker_social_media', 1372 'label' => __( 'Open link in a new tab', 'motivational-speaker' ), 1373 'choices' => array( 1374 '1' => __( 'On', 'motivational-speaker' ), 1375 'off' => __( 'Off', 'motivational-speaker' ), 1376 ), 1377 'active_callback' => '', 1378 ) 1379 ) 1380 ); 1381 1382 //Slider 1383 $wp_customize->add_section( 'motivational_speaker_slider_section' , array( 1384 'title' => __( 'Slider Settings', 'motivational-speaker' ), 1385 'priority' => 3, 1386 ) ); 1387 1388 $wp_customize->add_setting( 'motivational_speaker_section_slide_heading', array( 1389 'default' => '', 1390 'transport' => 'refresh', 1391 'sanitize_callback' => 'sanitize_text_field', 1392 ) ); 1393 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_slide_heading', array( 1394 'label' => esc_html__( 'Slider Settings', 'motivational-speaker' ), 1395 'description' => __( 'Slider Image Dimension ( 600px x 700px )', 'motivational-speaker' ), 1396 'section' => 'motivational_speaker_slider_section', 1397 'settings' => 'motivational_speaker_section_slide_heading', 1398 ) ) ); 1399 1400 $wp_customize->add_setting( 1401 'motivational_speaker_slider_arrows', 1402 array( 1403 'type' => 'option', 1404 'capability' => 'edit_theme_options', 1405 'theme_supports' => '', 1406 'default' => '', 1407 'transport' => 'refresh', 1408 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1409 ) 1410 ); 1411 $wp_customize->add_control( 1412 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1413 $wp_customize, 1414 'motivational_speaker_slider_arrows', 1415 array( 1416 'settings' => 'motivational_speaker_slider_arrows', 1417 'section' => 'motivational_speaker_slider_section', 1418 'label' => __( 'Check To Show Slider', 'motivational-speaker' ), 1419 'choices' => array( 1420 '1' => __( 'On', 'motivational-speaker' ), 1421 'off' => __( 'Off', 'motivational-speaker' ), 1422 ), 1423 'active_callback' => '', 1424 ) 1425 ) 1426 ); 1427 1428 $args = array('numberposts' => -1); 1429 $post_list = get_posts($args); 1430 $i = 0; 1431 $pst_sls[]= __('Select','motivational-speaker'); 1432 foreach ($post_list as $key => $p_post) { 1433 $pst_sls[$p_post->ID]=$p_post->post_title; 1434 } 1435 for ( $i = 1; $i <= 4; $i++ ) { 1436 $wp_customize->add_setting('motivational_speaker_post_setting'.$i,array( 1437 'sanitize_callback' => 'motivational_speaker_sanitize_select', 1438 )); 1439 $wp_customize->add_control('motivational_speaker_post_setting'.$i,array( 1440 'type' => 'select', 1441 'choices' => $pst_sls, 1442 'label' => __('Select post','motivational-speaker'), 1443 'section' => 'motivational_speaker_slider_section', 1444 'active_callback' => 'motivational_speaker_slider_dropdown' 1445 )); 1446 } 1447 wp_reset_postdata(); 1448 1449 $wp_customize->add_setting('motivational_speaker_slider_content_alignment',array( 1450 'default' => 'LEFT-ALIGN', 1451 'sanitize_callback' => 'motivational_speaker_sanitize_choices' 1452 )); 1453 $wp_customize->add_control('motivational_speaker_slider_content_alignment',array( 1454 'type' => 'select', 1455 'label' => __('Slider Content Alignment','motivational-speaker'), 1456 'section' => 'motivational_speaker_slider_section', 1457 'choices' => array( 1458 'LEFT-ALIGN' => __('LEFT-ALIGN','motivational-speaker'), 1459 'CENTER-ALIGN' => __('CENTER-ALIGN','motivational-speaker'), 1460 'RIGHT-ALIGN' => __('RIGHT-ALIGN','motivational-speaker'),), 1461 'active_callback' => 'motivational_speaker_slider_dropdown' 1462 ) ); 1463 1464 // Latest Program 1465 $wp_customize->add_section( 'motivational_speaker_middle_section' , array( 1466 'title' => __( 'Latest Program Settings', 'motivational-speaker' ), 1467 'priority' => 6, 1468 ) ); 1469 1470 $wp_customize->add_setting( 'motivational_speaker_section_latest_heading', array( 1471 'default' => '', 1472 'transport' => 'refresh', 1473 'sanitize_callback' => 'sanitize_text_field', 1474 ) ); 1475 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_latest_heading', array( 1476 'label' => esc_html__( 'Latest Program Settings', 'motivational-speaker' ), 1477 'section' => 'motivational_speaker_middle_section', 1478 'settings' => 'motivational_speaker_section_latest_heading', 1479 ) ) ); 1480 1481 $wp_customize->add_setting( 1482 'motivational_speaker_program_enable', 1483 array( 1484 'type' => 'option', 1485 'capability' => 'edit_theme_options', 1486 'theme_supports' => '', 1487 'default' => '', 1488 'transport' => 'refresh', 1489 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1490 ) 1491 ); 1492 $wp_customize->add_control( 1493 new Motivational_Speaker_Customizer_Customcontrol_Switch( 1494 $wp_customize, 1495 'motivational_speaker_program_enable', 1496 array( 1497 'settings' => 'motivational_speaker_program_enable', 1498 'section' => 'motivational_speaker_middle_section', 1499 'label' => __( 'Check To Show Section', 'motivational-speaker' ), 1500 'choices' => array( 1501 '1' => __( 'On', 'motivational-speaker' ), 1502 'off' => __( 'Off', 'motivational-speaker' ), 1503 ), 1504 'active_callback' => '', 1505 ) 1506 ) 1507 ); 1508 1509 $wp_customize->add_setting('motivational_speaker_program_section_title',array( 1510 'default' => '', 1511 'sanitize_callback' => 'sanitize_text_field' 1512 )); 1513 $wp_customize->add_control('motivational_speaker_program_section_title',array( 1514 'label' => esc_html__('Title','motivational-speaker'), 1515 'section' => 'motivational_speaker_middle_section', 1516 'setting' => 'motivational_speaker_program_section_title', 1517 'type' => 'text', 1518 'active_callback' => 'motivational_speaker_program_enable_dropdown' 1519 )); 1520 1521 $categories = get_categories(); 1522 $cats = array(); 1523 $i = 0; 1524 $cat_post[]= 'select'; 1525 foreach($categories as $category){ 1526 if($i==0){ 1527 $default = $category->slug; 1528 $i++; 1529 } 1530 $cat_post[$category->slug] = $category->name; 1531 } 1532 1533 $wp_customize->add_setting('motivational_speaker_latest_program_setting',array( 1534 'default' => 'select', 1535 'sanitize_callback' => 'motivational_speaker_sanitize_select', 1536 )); 1537 $wp_customize->add_control('motivational_speaker_latest_program_setting',array( 1538 'type' => 'select', 1539 'choices' => $cat_post, 1540 'label' => esc_html__('Select Category to display Latest Program','motivational-speaker'), 1541 'section' => 'motivational_speaker_middle_section', 1542 'active_callback' => 'motivational_speaker_program_enable_dropdown' 1543 )); 1544 $wp_customize->add_setting('motivational_speaker_front_date', 1545 array( 1546 'type' => 'option', 1547 'capability' => 'edit_theme_options', 1548 'theme_supports' => '', 1549 'default' => '1', 1550 'transport' => 'refresh', 1551 'sanitize_callback' => 'motivational_speaker_callback_sanitize_switch', 1552 ) 1553 ); 1554 $wp_customize->add_control(new Motivational_Speaker_Customizer_Customcontrol_Switch( 1555 $wp_customize, 1556 'motivational_speaker_front_date', 1557 array( 1558 'settings' => 'motivational_speaker_front_date', 1559 'section' => 'motivational_speaker_middle_section', 1560 'label' => __( 'show Date', 'motivational-speaker' ), 1561 'choices' => array( 1562 '1' => __( 'On', 'motivational-speaker' ), 1563 'off' => __( 'Off', 'motivational-speaker' ), 1564 ), 1565 'active_callback' => 'motivational_speaker_program_enable_dropdown', 1566 ) 1567 ) 1568 ); 1569 //Footer 1570 $wp_customize->add_section( 'motivational_speaker_footer_copyright', array( 1571 'title' => esc_html__( 'Footer Text', 'motivational-speaker' ), 1572 'priority' => 6 1573 ) ); 1574 1575 $wp_customize->add_setting( 'motivational_speaker_section_footer_heading', array( 1576 'default' => '', 1577 'transport' => 'refresh', 1578 'sanitize_callback' => 'sanitize_text_field', 1579 ) ); 1580 $wp_customize->add_control( new Motivational_Speaker_Customizer_Customcontrol_Section_Heading( $wp_customize, 'motivational_speaker_section_footer_heading', array( 1581 'label' => esc_html__( 'Footer Settings', 'motivational-speaker' ), 1582 'section' => 'motivational_speaker_footer_copyright', 1583 'settings' => 'motivational_speaker_section_footer_heading', 1584 ) ) ); 1585 1586 1587 $wp_customize->add_setting('motivational_speaker_footer_text',array( 1588 'default' => '', 1589 'sanitize_callback' => 'sanitize_text_field' 1590 )); 1591 $wp_customize->add_control('motivational_speaker_footer_text',array( 1592 'label' => esc_html__('Copyright Text','motivational-speaker'), 1593 'section' => 'motivational_speaker_footer_copyright', 1594 'type' => 'text' 1595 )); 1596 1597 1598 $wp_customize->add_setting('motivational_speaker_footer_widget',array( 1599 'default' => '4', 1600 'sanitize_callback' => 'motivational_speaker_sanitize_select' 1601 )); 1602 $wp_customize->add_control('motivational_speaker_footer_widget',array( 1603 'label' => esc_html__('Footer Per Column','motivational-speaker'), 1604 'section' => 'motivational_speaker_footer_copyright', 1605 'setting' => 'motivational_speaker_footer_widget', 1606 'type' => 'radio', 1607 'choices' => array( 1608 '1' => __('1 Column', 'motivational-speaker'), 1609 '2' => __('2 Column', 'motivational-speaker'), 1610 '3' => __('3 Column', 'motivational-speaker'), 1611 '4' => __('4 Column', 'motivational-speaker') 1612 ), 1613 )); 1212 1213 1614 1214 1615 1215 $wp_customize->get_setting( 'blogname' )->transport = 'postMessage'; -
motivational-speaker/3.0/inc/extra_customization.php
r205535 r207216 197 197 $motivational_speaker_custom_style .='}'; 198 198 } 199 // woocommerce breadcrumb 200 if( get_option( 'motivational_speaker_woocommerce_enable_breadcrumb',true) != 'on') { 201 202 $motivational_speaker_custom_style .='.woocommerce-breadcrumb{'; 203 204 $motivational_speaker_custom_style .='display: none;'; 205 206 $motivational_speaker_custom_style .='}'; 207 } 208 209 if( get_option( 'motivational_speaker_woocommerce_enable_breadcrumb',true) != 'off') { 210 211 $motivational_speaker_custom_style .='.woocommerce-breadcrumb{'; 212 213 $motivational_speaker_custom_style .='display: block;'; 214 215 $motivational_speaker_custom_style .='}'; 216 } -
motivational-speaker/3.0/page-template/left-sidebar.php
r205535 r207216 9 9 <?php while ( have_posts() ) : the_post(); ?> 10 10 <div id="post-<?php the_ID(); ?>" class="outer-div"> 11 <div class="single-post-image"> 12 <?php the_post_thumbnail(); ?> 13 </div> 11 <?php if(has_post_thumbnail()){ ?> 12 <div class="single-post-image"> 13 <?php the_post_thumbnail(); ?> 14 </div> 15 <?php } 16 else { ?> 17 <div class="header-image"></div> 18 <?php } ?> 14 19 <div class="inner-div"> 15 20 <?php //breadcrumb 16 21 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 17 if( get_option('motivational_speaker_ enable_breadcrumb',false) != 'off'){ ?>22 if( get_option('motivational_speaker_single_enable_breadcrumb',false) != 'off'){ ?> 18 23 <div class="bread_crumb align-self-center text-center"> 19 24 <?php motivational_speaker_breadcrumb(); ?> -
motivational-speaker/3.0/page-template/right-sidebar.php
r205535 r207216 8 8 <?php while ( have_posts() ) : the_post(); ?> 9 9 <div id="post-<?php the_ID(); ?>" class="outer-div"> 10 <div class="single-post-image"> 11 <?php the_post_thumbnail(); ?> 12 </div> 10 <?php if(has_post_thumbnail()){ ?> 11 <div class="single-post-image"> 12 <?php the_post_thumbnail(); ?> 13 </div> 14 <?php } 15 else { ?> 16 <div class="header-image"></div> 17 <?php } ?> 13 18 <div class="inner-div"> 14 19 <?php //breadcrumb 15 20 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 16 if( get_option('motivational_speaker_enable_breadcrumb',false) != 'off'){ ?> 17 <div class="bread_crumb align-self-center text-center"> 18 <?php motivational_speaker_breadcrumb(); ?> 19 </div> 20 <?php } 21 }?> 22 <?php //breadcrumb 23 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 24 if( get_option('motivational_speaker_enable_breadcrumb',false) != 'off'){ ?> 21 if( get_option('motivational_speaker_single_enable_breadcrumb',false) != 'off'){ ?> 25 22 <div class="bread_crumb align-self-center text-center"> 26 23 <?php motivational_speaker_breadcrumb(); ?> -
motivational-speaker/3.0/page.php
r205535 r207216 12 12 <?php while ( have_posts() ) : the_post(); ?> 13 13 <div id="post-<?php the_ID(); ?>" class="outer-div"> 14 <div class="single-post-image"> 15 <?php the_post_thumbnail(); ?> 16 </div> 14 <?php if(has_post_thumbnail()){ ?> 15 <div class="single-post-image"> 16 <?php the_post_thumbnail(); ?> 17 </div> 18 <?php } 19 else { ?> 20 <div class="header-image"></div> 21 <?php } ?> 17 22 <div class="inner-div"> 18 23 <?php //breadcrumb 19 24 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 20 if( get_option('motivational_speaker_ enable_breadcrumb',false) != 'off'){ ?>25 if( get_option('motivational_speaker_single_enable_breadcrumb',false) != 'off'){ ?> 21 26 <div class="bread_crumb align-self-center text-center"> 22 27 <?php motivational_speaker_breadcrumb(); ?> -
motivational-speaker/3.0/readme.txt
r205535 r207216 5 5 Requires PHP: 5.6 6 6 Tested up to: 6.3 7 Stable tag: 2.97 Stable tag: 3.0 8 8 License: GNU General Public License v3 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-3.0.html … … 133 133 -- Updated navigation css. 134 134 135 = 3.0 = 136 -- updated rtl.css file 137 -- Added tags list on single post page. 138 -- Added tag meta for post. 139 -- Added post meta icon change setting. 140 -- Updated post meta css. 141 -- Added setting for archieve post layout excerpt. 142 -- Added toggle for single post pages breadcrumb. 143 -- Added toggle for woocommerce breadcrumb. 144 -- Updated 404 page css. 145 -- Added buttonset radio control. 146 -- Updated customizer sections. 147 135 148 == Resources == 136 149 -
motivational-speaker/3.0/style-rtl.css
r205535 r207216 111 111 .single .entry-content p{ 112 112 margin-bottom: 18px; 113 } 114 .entry-content > p:first-of-type:first-letter{ 115 font-size: 70px; 116 float: right; 117 line-height: 60px; 118 padding-top: 4px; padding-left: 12px; padding-bottom: 0; padding-right: 0; 113 119 } 114 120 .entry-content p a,.comment-content p a,span.entry-author a, … … 449 455 padding:15px 0; 450 456 border-left: solid 1px #eee; 457 text-align: right; 451 458 } 452 459 .logo h1, … … 487 494 font-weight: 600; 488 495 font-size: 15px; 496 text-align: right; 497 } 498 .mailling-box p{ 499 text-align: right; 489 500 } 490 501 .media-box i { … … 852 863 853 864 #Category-section{ 854 padding-bottom: 25px;855 865 width: 100%; 856 866 } … … 875 885 #Category-section .date-box{ 876 886 font-size: 13px; 877 font-weight: 600 878 } 879 887 font-weight: 600; 888 color:#222222; 889 } 880 890 /*--------- Woocommerce Section--------- */ 881 891 … … 1113 1123 height: 400px; 1114 1124 object-fit: cover; 1115 opacity: 0. 3;1125 opacity: 0.5; 1116 1126 width: 100%; 1117 1127 } … … 1230 1240 margin-bottom: 0px; 1231 1241 } 1232 .page-template-custom-home-page #header,1233 .woocommerce-page #header,1234 .search #header,1235 .home #header,1236 .archive #header{1237 background-image: none !important;1238 }1239 1242 .page-header{ 1240 1243 position: relative; … … 1251 1254 height: 400px; 1252 1255 object-fit: cover; 1253 opacity: 0. 3;1256 opacity: 0.5; 1254 1257 width: 100%; 1255 1258 } … … 1590 1593 padding-inline-start: 0px; 1591 1594 } 1595 .single-tags a, 1592 1596 #sidebar .tagcloud a, 1593 1597 .site-footer .tagcloud a, p.wp-block-tag-cloud a{ … … 1599 1603 display:inline-block; 1600 1604 } 1605 .single-tags a:hover, 1601 1606 #sidebar .tagcloud a:hover, 1602 1607 .site-footer .tagcloud a:hover, p.wp-block-tag-cloud a:hover{ … … 1904 1909 display: none; 1905 1910 } 1911 .mailling-box h6, 1912 .mailling-box p, 1913 .logo{ 1914 text-align: center; 1915 } 1906 1916 .logo,.top_bar{ 1907 1917 border: none; … … 1960 1970 1961 1971 } 1962 @media screen and (max-width: 1024px){1972 @media screen and (max-width:1024px) and (min-width: 992px){ 1963 1973 1964 1974 #slider .bg-color{ 1965 1975 height: 400px; 1966 1976 } 1967 } 1977 .media-box i { 1978 width: 25px; 1979 height: 25px; 1980 border-radius: 30px; 1981 font-size: 11px; 1982 padding: 7px 0; 1983 text-align: center; 1984 } 1985 } -
motivational-speaker/3.0/style.css
r205535 r207216 5 5 Author URI: https://www.ovationthemes.com/ 6 6 Description: Motivational Speaker is a multipurpose WordPress theme suitable to create a fabulous website for health coach, fitness, life coach, pep talks, mentor, dietitian, wellness, yoga, business coach or consulting, therapist, psychologist, personal development, motivational speaker, political party or event, and such related websites. The theme is based on the powerful bootstrap framework which makes it highly functional and easy to operate. Using various layouts and widgets you can show your missions, priorities, skills and achievements. Also, you can showcase your services and portfolio in a professional manner. The translation option allows translating the theme into any language with ease. With our theme, you may use Instagram and Events Calendar on your website (e.g to inform readers and your clients about your master classes and seminars). It is SEO-friendly as well as has a responsive layout. It is optimized for speed and the codes used are clean and secure. It comes with complete documentation. 7 Version: 2.97 Version: 3.0 8 8 Requires at least: 5.0 9 9 Tested up to: 6.3 … … 129 129 .single .entry-content p{ 130 130 margin-bottom: 18px; 131 } 132 .entry-content > p:first-of-type:first-letter{ 133 font-size: 70px; 134 float: left; 135 line-height: 60px; 136 padding: 4px 12px 0 0; 131 137 } 132 138 .entry-content p a,.comment-content p a,span.entry-author a, … … 870 876 871 877 #Category-section{ 872 padding-bottom: 25px;873 878 width: 100%; 874 879 } … … 893 898 #Category-section .date-box{ 894 899 font-size: 13px; 895 font-weight: 600 896 } 897 900 font-weight: 600; 901 color:#222222; 902 } 898 903 /*--------- Woocommerce Section--------- */ 899 904 … … 1131 1136 height: 400px; 1132 1137 object-fit: cover; 1133 opacity: 0. 3;1138 opacity: 0.5; 1134 1139 width: 100%; 1135 1140 } … … 1248 1253 margin-bottom: 0px; 1249 1254 } 1250 .page-template-custom-home-page #header,1251 .woocommerce-page #header,1252 .search #header,1253 .home #header,1254 .archive #header{1255 background-image: none !important;1256 }1257 1255 .page-header{ 1258 1256 position: relative; … … 1269 1267 height: 400px; 1270 1268 object-fit: cover; 1271 opacity: 0. 3;1269 opacity: 0.5; 1272 1270 width: 100%; 1273 1271 } … … 1608 1606 padding-inline-start: 0px; 1609 1607 } 1608 .single-tags a, 1610 1609 #sidebar .tagcloud a, 1611 1610 .site-footer .tagcloud a, p.wp-block-tag-cloud a{ … … 1617 1616 display:inline-block; 1618 1617 } 1618 .single-tags a:hover, 1619 1619 #sidebar .tagcloud a:hover, 1620 1620 .site-footer .tagcloud a:hover, p.wp-block-tag-cloud a:hover{ … … 1978 1978 1979 1979 } 1980 @media screen and (max-width: 1024px){1980 @media screen and (max-width:1024px) and (min-width: 992px){ 1981 1981 1982 1982 #slider .bg-color{ 1983 1983 height: 400px; 1984 1984 } 1985 } 1985 .media-box i { 1986 width: 25px; 1987 height: 25px; 1988 border-radius: 30px; 1989 font-size: 11px; 1990 padding: 7px 0; 1991 text-align: center; 1992 } 1993 } -
motivational-speaker/3.0/template-parts/post/content-audio.php
r205535 r207216 15 15 <div id="Category-section" class="entry-content"> 16 16 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 17 <div class="postbox smallpostimage p- 2">17 <div class="postbox smallpostimage p-3"> 18 18 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 19 19 <?php … … 32 32 <div class="date-box mb-2"> 33 33 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 34 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>34 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 35 35 <?php } ?> 36 36 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 37 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>37 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 38 38 <?php }?> 39 39 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 40 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 40 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 41 <?php }?> 42 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 43 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 41 44 <?php }?> 42 45 </div> 43 <p><?php the_excerpt();?></p> 46 <div class="link-more mb-2"> 47 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 48 </div> 44 49 </div> 45 50 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/content-gallery.php
r205535 r207216 10 10 <div id="Category-section" class="entry-content"> 11 11 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 12 <div class="postbox smallpostimage p- 2">12 <div class="postbox smallpostimage p-3"> 13 13 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 14 14 <?php … … 25 25 <div class="date-box mb-2"> 26 26 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 27 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>27 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 28 28 <?php } ?> 29 29 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 30 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>30 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 31 31 <?php }?> 32 32 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 33 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 33 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 34 <?php }?> 35 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 36 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 34 37 <?php }?> 35 38 </div> 36 39 <div class="link-more mb-2"> 40 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 41 </div> 37 42 </div> 38 43 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/content-image.php
r205535 r207216 9 9 <div id="Category-section" class="entry-content"> 10 10 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 11 <div class="postbox smallpostimage p- 2">11 <div class="postbox smallpostimage p-3"> 12 12 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 13 13 <div class="box-content text-center"> … … 36 36 <div class="date-box mb-2"> 37 37 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 38 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>38 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 39 39 <?php } ?> 40 40 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 41 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>41 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 42 42 <?php }?> 43 43 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 44 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 44 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 45 <?php }?> 46 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 47 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 45 48 <?php }?> 46 49 </div> 47 50 <div class="link-more mb-2"> 51 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 52 </div> 48 53 </div> 49 54 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/content-quote.php
r205535 r207216 10 10 <div id="Category-section" class="entry-content"> 11 11 <div id="post-<?php the_ID(); ?>" <?php post_class('quotepost'); ?>> 12 <div class="postbox smallpostimage p- 2">12 <div class="postbox smallpostimage p-3"> 13 13 <div class="box-content text-center"> 14 14 <a href="<?php the_permalink(); ?>"><h1 class="quote-content"><?php echo get_the_content();?></h1></a> … … 18 18 <div class="date-box mb-2"> 19 19 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 20 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>20 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 21 21 <?php } ?> 22 22 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 23 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>23 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 24 24 <?php }?> 25 25 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 26 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 26 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 27 <?php }?> 28 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 29 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 27 30 <?php }?> 28 31 </div> 29 30 32 </div> 31 33 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/content-video.php
r205535 r207216 12 12 <div id="Category-section" class="entry-content"> 13 13 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 14 <div class="postbox smallpostimage p- 2">14 <div class="postbox smallpostimage p-3"> 15 15 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 16 16 <?php … … 29 29 <div class="date-box mb-2"> 30 30 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 31 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>31 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 32 32 <?php } ?> 33 33 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 34 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>34 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 35 35 <?php }?> 36 36 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 37 <span class="entry-comments "><i class="fas fa-commentsmr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span>37 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 38 38 <?php }?> 39 </div> 40 <p><?php the_excerpt();?></p> 39 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 40 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 41 <?php }?> 42 </div> 43 <div class="link-more"> 44 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 45 </div> 41 46 </div> 42 47 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/content.php
r205535 r207216 10 10 <div id="Category-section" class="entry-content"> 11 11 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 12 <div class="postbox smallpostimage p- 2">12 <div class="postbox smallpostimage p-3"> 13 13 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 14 14 <?php … … 21 21 <div class="date-box mb-2"> 22 22 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 23 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>23 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 24 24 <?php } ?> 25 25 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 26 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>26 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 27 27 <?php }?> 28 28 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 29 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 29 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 30 <?php }?> 31 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 32 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 30 33 <?php }?> 31 34 </div> 32 <p><?php the_excerpt();?></p>35 <p><?php motivational_speaker_custom_excerpt(); ?></p> 33 36 </div> 34 37 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/grid-audio.php
r205535 r207216 18 18 <?php }else if($post_option == '4_column'){ ?> 19 19 <div class="col-lg-3 col-md-3"> 20 <?php }else if($post_option == '5_column'){ ?>21 <div class="col-lg-2 col-md-2">22 20 <?php }?> 23 21 <?php … … 28 26 <div id="Category-section" class="entry-content w-100"> 29 27 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 30 <div class="postbox smallpostimage p- 2">28 <div class="postbox smallpostimage p-3"> 31 29 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 32 30 <?php … … 45 43 <div class="date-box mb-2"> 46 44 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 47 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>45 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 48 46 <?php } ?> 49 47 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 50 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>48 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 51 49 <?php }?> 52 50 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 53 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 51 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 52 <?php }?> 53 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 54 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 54 55 <?php }?> 55 56 </div> 56 <p><?php the_excerpt();?></p> 57 <div class="link-more mb-2"> 58 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 59 </div> 57 60 </div> 58 61 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/grid-gallery.php
r205535 r207216 18 18 <?php }else if($post_option == '4_column'){ ?> 19 19 <div class="col-lg-3 col-md-3"> 20 <?php }else if($post_option == '5_column'){ ?>21 <div class="col-lg-2 col-md-2">22 20 <?php }?> 23 21 <div id="Category-section" class="entry-content w-100"> 24 22 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 25 <div class="postbox smallpostimage p- 2">23 <div class="postbox smallpostimage p-3"> 26 24 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 27 25 <div class="box-content text-center"> … … 32 30 <div class="date-box mb-2"> 33 31 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 34 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>32 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 35 33 <?php } ?> 36 34 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 37 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>35 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 38 36 <?php }?> 39 37 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 40 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 38 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 39 <?php }?> 40 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 41 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 41 42 <?php }?> 42 43 </div> 43 44 <div class="link-more mb-2"> 45 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 46 </div> 44 47 </div> 45 48 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/grid-image.php
r205535 r207216 18 18 <?php }else if($post_option == '4_column'){ ?> 19 19 <div class="col-lg-3 col-md-3"> 20 <?php }else if($post_option == '5_column'){ ?>21 <div class="col-lg-2 col-md-2">22 20 <?php }?> 23 21 <div id="Category-section" class="entry-content w-100"> 24 22 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 25 <div class="postbox smallpostimage p- 2">23 <div class="postbox smallpostimage p-3"> 26 24 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 27 25 <div class="box-content text-center"> … … 50 48 <div class="date-box mb-2"> 51 49 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 52 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>50 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 53 51 <?php } ?> 54 52 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 55 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>53 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 56 54 <?php }?> 57 55 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 58 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 56 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 57 <?php }?> 58 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 59 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 59 60 <?php }?> 60 61 </div> 61 62 <div class="link-more mb-2"> 63 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 64 </div> 62 65 </div> 63 66 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/grid-quote.php
r205535 r207216 18 18 <?php }else if($post_option == '4_column'){ ?> 19 19 <div class="col-lg-3 col-md-3"> 20 <?php }else if($post_option == '5_column'){ ?>21 <div class="col-lg-2 col-md-2">22 20 <?php }?> 23 21 <div id="Category-section" class="entry-content w-100"> 24 22 <div id="post-<?php the_ID(); ?>" <?php post_class('quotepost'); ?>> 25 <div class="postbox smallpostimage p- 2">23 <div class="postbox smallpostimage p-3"> 26 24 <div class="box-content text-center"> 27 25 <a href="<?php the_permalink(); ?>"><h1 class="quote-content"><?php echo get_the_content();?></h1></a> … … 31 29 <div class="date-box mb-2"> 32 30 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 33 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>31 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 34 32 <?php } ?> 35 33 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 36 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>34 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 37 35 <?php }?> 38 36 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 39 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 37 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 38 <?php }?> 39 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 40 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 40 41 <?php }?> 41 42 </div> 42 43 43 </div> 44 44 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/grid-video.php
r205535 r207216 18 18 <?php }else if($post_option == '4_column'){ ?> 19 19 <div class="col-lg-3 col-md-3"> 20 <?php }else if($post_option == '5_column'){ ?>21 <div class="col-lg-2 col-md-2">22 20 <?php }?> 23 21 <?php … … 26 24 <div id="Category-section" class="entry-content w-100"> 27 25 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 28 <div class="postbox smallpostimage p- 2">26 <div class="postbox smallpostimage p-3"> 29 27 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 30 28 <?php … … 43 41 <div class="date-box mb-2"> 44 42 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 45 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>43 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 46 44 <?php } ?> 47 45 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 48 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>46 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 49 47 <?php }?> 50 48 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 51 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 49 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 50 <?php }?> 51 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 52 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 52 53 <?php }?> 53 54 </div> 54 <p><?php the_excerpt();?></p> 55 <div class="link-more mb-2"> 56 <a class="more-link py-2 px-4" href="<?php get_the_title( get_the_ID() ); ?>"><?php echo esc_html('Read More','motivational-speaker'); ?></a> 57 </div> 55 58 </div> 56 59 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/grid.php
r205535 r207216 18 18 <?php }else if($post_option == '4_column'){ ?> 19 19 <div class="col-lg-3 col-md-3"> 20 <?php }else if($post_option == '5_column'){ ?>21 <div class="col-lg-2 col-md-2">22 20 <?php }?> 23 21 <div id="Category-section" class="entry-content w-100"> 24 22 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 25 <div class="postbox smallpostimage p- 2">23 <div class="postbox smallpostimage p-3"> 26 24 <h3 class="text-center"><a href="<?php the_permalink(); ?>"><?php the_title();?></a></h3> 27 25 <?php … … 34 32 <div class="date-box mb-2"> 35 33 <?php if( get_option('motivational_speaker_date',false) != 'off'){ ?> 36 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>34 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 37 35 <?php } ?> 38 36 <?php if( get_option('motivational_speaker_admin',false) != 'off'){ ?> 39 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>37 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 40 38 <?php }?> 41 39 <?php if( get_option('motivational_speaker_comment',false) != 'off'){ ?> 42 <span class="entry-comments"><i class="fas fa-comments mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 40 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 41 <?php }?> 42 <?php if( get_option('motivational_speaker_tag',false) != 'off'){ ?> 43 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 43 44 <?php }?> 44 45 </div> 45 <p><?php the_excerpt();?></p>46 <p><?php motivational_speaker_custom_excerpt(); ?></p> 46 47 </div> 47 48 <div class="clearfix"></div> -
motivational-speaker/3.0/template-parts/post/single-page.php
r205535 r207216 11 11 <?php while ( have_posts() ) : the_post(); ?> 12 12 <div id="post-<?php the_ID(); ?>" class="outer-div"> 13 <div class="single-post-image"> 14 <?php the_post_thumbnail(); ?> 15 </div> 13 <?php if(has_post_thumbnail()){ ?> 14 <div class="single-post-image"> 15 <?php the_post_thumbnail(); ?> 16 </div> 17 <?php } 18 else { ?> 19 <div class="header-image"></div> 20 <?php } ?> 16 21 <div class="inner-div"> 17 22 <?php //breadcrumb 18 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) {19 if( get_option('motivational_speaker_enable_breadcrumb',false) != 'off'){ ?>20 <div class="bread_crumb align-self-center text-center">21 <?php motivational_speaker_breadcrumb(); ?>22 </div>23 <?php }24 }?>25 <h2 class="my-4 text-center"><?php the_title();?></h2>23 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 24 if( get_option('motivational_speaker_single_enable_breadcrumb',false) != 'off'){ ?> 25 <div class="bread_crumb align-self-center text-center"> 26 <?php motivational_speaker_breadcrumb(); ?> 27 </div> 28 <?php } 29 }?> 30 <h2 class="my-4 text-center"><?php the_title();?></h2> 26 31 <div class="date-box text-center my-3 align-self-center"> 27 32 <?php if( get_option('motivational_speaker_single_post_date',false) != 'off'){ ?> 28 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>33 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 29 34 <?php } ?> 30 35 <?php if( get_option('motivational_speaker_single_post_admin',false) != 'off'){ ?> 31 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>36 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 32 37 <?php }?> 33 38 <?php if( get_option('motivational_speaker_single_post_comment',false) != 'off'){ ?> 34 <span class="entry-comments "><i class="fas fa-commentsmr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span>39 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 35 40 <?php }?> 41 <?php if( get_option('motivational_speaker_single_post_tag_count',false) != 'off'){ ?> 42 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 43 <?php }?> 36 44 </div> 37 45 </div> … … 52 60 <?php the_content(); ?> 53 61 </div> 62 <?php if( get_option('motivational_speaker_single_post_tag',false) != 'off'){ ?> 63 <?php if (has_tag()) { 64 $tags_list = get_the_tag_list('Tags: ', ' '); 65 if ($tags_list) { 66 echo '<div class="single-tags py-3">' . $tags_list . '</div>'; 67 } 68 } 69 }?> 54 70 <div class="clearfix"></div> 55 71 </div> … … 80 96 <?php while ( have_posts() ) : the_post(); ?> 81 97 <div id="post-<?php the_ID(); ?>" class="outer-div"> 82 <div class="single-post-image"> 83 <?php the_post_thumbnail(); ?> 84 </div> 98 <?php if(has_post_thumbnail()){ ?> 99 <div class="single-post-image"> 100 <?php the_post_thumbnail(); ?> 101 </div> 102 <?php } 103 else { ?> 104 <div class="header-image"></div> 105 <?php } ?> 85 106 <div class="inner-div"> 86 107 <?php //breadcrumb 87 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) {88 if( get_option('motivational_speaker_enable_breadcrumb',false) != 'off'){ ?>89 <div class="bread_crumb align-self-center text-center">90 <?php motivational_speaker_breadcrumb(); ?>91 </div>92 <?php }93 }?>94 <h2 class="my-4 text-center"><?php the_title();?></h2>108 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 109 if( get_option('motivational_speaker_single_enable_breadcrumb',false) != 'off'){ ?> 110 <div class="bread_crumb align-self-center text-center"> 111 <?php motivational_speaker_breadcrumb(); ?> 112 </div> 113 <?php } 114 }?> 115 <h2 class="my-4 text-center"><?php the_title();?></h2> 95 116 <div class="date-box text-center my-3 align-self-center"> 96 117 <?php if( get_option('motivational_speaker_single_post_date',false) != 'off'){ ?> 97 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>118 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 98 119 <?php } ?> 99 120 <?php if( get_option('motivational_speaker_single_post_admin',false) != 'off'){ ?> 100 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>121 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 101 122 <?php }?> 102 123 <?php if( get_option('motivational_speaker_single_post_comment',false) != 'off'){ ?> 103 <span class="entry-comments "><i class="fas fa-commentsmr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span>124 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 104 125 <?php }?> 126 <?php if( get_option('motivational_speaker_single_post_tag_count',false) != 'off'){ ?> 127 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 128 <?php }?> 105 129 </div> 106 130 </div> … … 122 146 <?php the_content(); ?> 123 147 </div> 148 <?php if( get_option('motivational_speaker_single_post_tag',false) != 'off'){ ?> 149 <?php if (has_tag()) { 150 $tags_list = get_the_tag_list('Tags: ', ' '); 151 if ($tags_list) { 152 echo '<div class="single-tags py-3">' . $tags_list . '</div>'; 153 } 154 } 155 }?> 124 156 <div class="clearfix"></div> 125 157 </div> … … 149 181 <?php while ( have_posts() ) : the_post(); ?> 150 182 <div id="post-<?php the_ID(); ?>" class="outer-div"> 151 <div class="single-post-image"> 152 <?php the_post_thumbnail(); ?> 153 </div> 183 <?php if(has_post_thumbnail()){ ?> 184 <div class="single-post-image"> 185 <?php the_post_thumbnail(); ?> 186 </div> 187 <?php } 188 else { ?> 189 <div class="header-image"></div> 190 <?php } ?> 154 191 <div class="inner-div"> 155 <?php //breadcrumb156 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) {157 if( get_option('motivational_speaker_enable_breadcrumb',false) != 'off'){ ?>158 <div class="bread_crumb align-self-center text-center">159 <?php motivational_speaker_breadcrumb(); ?>160 </div>161 <?php }162 }?>163 <h2 class="my-4 text-center"><?php the_title();?></h2>192 <?php //breadcrumb 193 if ( !is_page_template( 'page-template/custom-home-page.php' ) ) { 194 if( get_option('motivational_speaker_single_enable_breadcrumb',false) != 'off'){ ?> 195 <div class="bread_crumb align-self-center text-center"> 196 <?php motivational_speaker_breadcrumb(); ?> 197 </div> 198 <?php } 199 }?> 200 <h2 class="my-4 text-center"><?php the_title();?></h2> 164 201 <div class="date-box text-center my-3 align-self-center"> 165 202 <?php if( get_option('motivational_speaker_single_post_date',false) != 'off'){ ?> 166 <span class="mr-2"><i class=" far fa-calendar-altmr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span>203 <span class="mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_date_icon','far fa-calendar-alt')); ?> mr-2"></i><?php the_time( get_option( 'date_format' ) ); ?></span> 167 204 <?php } ?> 168 205 <?php if( get_option('motivational_speaker_single_post_admin',false) != 'off'){ ?> 169 <span class="entry-author mr-2"><i class=" far fa-usermr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span>206 <span class="entry-author mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_author_icon','fas fa-user')); ?> mr-2"></i><a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' )) ); ?>"><?php the_author(); ?></a></span> 170 207 <?php }?> 171 208 <?php if( get_option('motivational_speaker_single_post_comment',false) != 'off'){ ?> 172 <span class="entry-comments "><i class="fas fa-commentsmr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span>209 <span class="entry-comments mr-2"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_comment_icon','fas fa-comments')); ?> mr-2"></i> <?php comments_number( __('0 Comments','motivational-speaker'), __('0 Comments','motivational-speaker'), __('% Comments','motivational-speaker')); ?></span> 173 210 <?php }?> 211 <?php if( get_option('motivational_speaker_single_post_tag_count',false) != 'off'){ ?> 212 <span class="tags"><i class="<?php echo esc_attr(get_theme_mod('motivational_speaker_single_tag_icon','fas fa-tags')); ?> mr-2"></i> <?php display_post_tag_count(); ?></span> 213 <?php }?> 174 214 </div> 175 215 </div> … … 190 230 <?php the_content(); ?> 191 231 </div> 232 <?php if( get_option('motivational_speaker_single_post_tag',false) != 'off'){ ?> 233 <?php if (has_tag()) { 234 $tags_list = get_the_tag_list('Tags: ', ' '); 235 if ($tags_list) { 236 echo '<div class="single-tags py-3">' . $tags_list . '</div>'; 237 } 238 } 239 }?> 192 240 <div class="clearfix"></div> 193 241 </div>
Note: See TracChangeset
for help on using the changeset viewer.