$word_limit) array_pop($words); return implode(' ', $words); } function ca_painting_excerpt_more( $link ) { if ( is_admin() ) { return $link; } $link = sprintf( '
', esc_url( get_permalink( get_the_ID() ) ), /* translators: %s: Name of current post */ sprintf( __( 'Continue reading "%s"', 'ca-painting' ), get_the_title( get_the_ID() ) ) ); return ' … ' . $link; } add_filter( 'excerpt_more', 'ca_painting_excerpt_more' ); function ca_painting_start_set() { load_theme_textdomain( 'ca-painting', get_template_directory() . '/languages' ); add_theme_support( 'title-tag' ); add_theme_support( 'wc-product-gallery-zoom' ); add_theme_support( 'wc-product-gallery-lightbox' ); add_theme_support( 'wc-product-gallery-slider' ); add_theme_support( 'automatic-feed-links' ); add_theme_support( 'post-thumbnails' ); add_theme_support( 'woocommerce' ); add_theme_support( 'custom-header' ); add_theme_support( 'custom-logo', array( 'height' => 240, 'width' => 240, 'flex-height' => true, ) ); add_image_size('ca-painting-homepage-thumb',240,145,true); register_nav_menus( array( 'primary' => __( 'Primary Menu', 'ca-painting' ) ) ); add_theme_support( 'custom-background', array( 'default-color' => 'f1f1f1' ) ); add_editor_style( array( 'assets/css/editor-style.css') ); } endif; add_action( 'after_setup_theme', 'ca_painting_start_set' ); function ca_painting_add_scripts_to_theme() { wp_enqueue_style( 'ca-painting-font-theme', ca_painting_font_url(), array() ); wp_enqueue_style( 'font-awesome', get_template_directory_uri().'/assets/css/fontawesome-all.min.css' ); wp_enqueue_style( 'bootstrap-style-theme', get_template_directory_uri().'/assets/css/boot/bootstrap.min.css' ); wp_enqueue_style( 'ca-painting-basic-style', get_stylesheet_uri() ); wp_style_add_data( 'ca-painting-style', 'rtl', 'replace' ); wp_enqueue_style( 'animation-wow', get_template_directory_uri().'/assets/css/animation/animation.css' ); wp_enqueue_style( 'effect', get_template_directory_uri().'/assets/css/other/effect.css' ); wp_enqueue_style( 'owl-carousel-style', get_template_directory_uri().'/assets/css/other/owl.carousel.css' ); wp_enqueue_script( 'tether', get_template_directory_uri() . '/assets/js/other/tether.js', array('jquery'), '',true); wp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/assets/js/boot/bootstrap.min.js',array('jquery'),'',true); wp_enqueue_script( 'superfsh', get_template_directory_uri() . '/assets/js/menu/jquery.superfish.js',array('jquery'),'',true); wp_enqueue_script( 'owl-carousel', get_template_directory_uri() . '/assets/js/loop/owl.carousel.js',array('jquery'),'',true); wp_enqueue_script( 'smooth-scroll', get_template_directory_uri() . '/assets/js/loop/SmoothScroll.js',array('jquery'),'',true); wp_enqueue_script( 'ca-painting-customscripts', get_template_directory_uri() . '/assets/js/main/mainjsfile.js', array('jquery'),'', true ); wp_enqueue_style('ca-painting-ie', get_template_directory_uri().'/assets/css/ie.css', array('ca-painting-basic-style')); wp_style_add_data( 'ca-painting-ie', 'conditional', 'IE' ); } add_action( 'wp_enqueue_scripts', 'ca_painting_add_scripts_to_theme' ); define('SITE_URL','https://chitrarchana.com/'); function ca_painting_credit_link() { echo esc_html_e('Credit @ ','ca-painting'). " CA Themes"; } function ca_painting_sanitize_choices( $input, $setting ) { global $wp_customize; $control = $wp_customize->get_control( $setting->id ); if ( array_key_exists( $input, $control->choices ) ) { return $input; } else { return $setting->default; } } function ca_painting_the_breadcrumb() { if (!is_home()) { echo ''; bloginfo('name'); echo " "; if (is_category() || is_single()) { the_category(', '); if (is_single()) { echo " "; the_title(); echo " "; } } elseif (is_page()) { the_title(); } } } function ca_painting_widgets_init() { register_sidebar( array( 'name' => __( 'Sidebar', 'ca-painting' ), 'description' => __( 'Appears on blog page sidebar', 'ca-painting' ), 'id' => 'sidebar', 'before_widget' => '', 'before_title' => '