', esc_url( get_bloginfo( 'pingback_url' ) ) ); } } add_action( 'wp_head', 'oro_pingback_header' ); /** * Pagination */ function oro_get_pagination() { $args = array( 'mid_size' => 2, 'prev_text' => __( '', 'oro' ), 'next_text' => __( '', 'oro' ), ); the_posts_pagination($args); } add_action('oro_pagination', 'oro_get_pagination'); /** * Function to call Featured Image */ function oro_get_featured_thumnail( $layout ) { if ( has_post_thumbnail() ) : ?> Featured Thumbnail '; ?> ' . esc_html(get_cat_name($cat)) . ''; } $link_html .= ''; echo $link_html; ?> '; comments_popup_link( sprintf( wp_kses( /* translators: %s: post title */ __( 'Leave a Comment on %s', 'oro' ), array( 'span' => array( 'class' => array(), ), ) ), wp_kses_post( get_the_title() ) ) ); echo ''; } } /** * Function to generate meta data for the posts */ function oro_get_metadata() { if ( 'post' === get_post_type() ) : ?>

ID) && has_excerpt($post->ID) ) { $output = $post->post_excerpt; } elseif ( isset( $post->post_content ) ) { if ( strpos($post->post_content, '') ) { $output = get_the_content(''); } else { $output = wp_trim_words( strip_shortcodes( $post->post_content ), $length ); } } $output = apply_filters('oro_excerpt', $output); echo $output; } add_action('oro_blog_excerpt', 'oro_get_blog_excerpt', 10, 1); function oro_get_layout( $template = 'blog') { $layout = 'framework/layouts/content'; switch( $template ) { case 'blog': get_template_part( $layout, get_theme_mod("oro_blog_layout", "blog" ), array('columns' => 'col-md-6') ); break; case 'single': get_template_part( 'template-parts/content', 'single' ); break; case 'search': get_template_part( $layout, get_theme_mod("oro_search_layout", "blog" ), array('columns' => 'col-md-6') ); break; case 'archive': get_template_part( $layout, get_theme_mod("oro_archive_layout", "blog" ), array('columns' => 'col-md-6') ); break; default: get_template_part( $layout, get_theme_mod('oro_blog_layout', 'blog' ), array('columns' => 'col-md-6') ); } } add_action('oro_layout', 'oro_get_layout', 10, 1); /** * Function for 'Read More' link */ function oro_read_more_link() { ?>
'blog']); } break; case "single": if( is_single() && get_theme_mod('oro_single_sidebar_enable', 1) !== "" ) { get_sidebar('single'); } break; case "search": if( is_search() && get_theme_mod('oro_search_sidebar_enable', 1) !== "" ) { get_sidebar(NULL, ['page' => 'search']); } break; case "archive": if( is_archive() && get_theme_mod('oro_archive_sidebar_enable', 1) !== "" ) { get_sidebar(NULL, ['page' => 'archive']); } break; case "page": if ( '' == get_post_meta($post->ID, 'enable-sidebar', true) ) { get_sidebar('page'); } break; default: get_sidebar(); } } add_action('oro_sidebar', 'oro_get_sidebar', 10, 1); /** * Function for Sidebar alignment */ function oro_sidebar_align( $template = 'blog' ) { $align = 'page' == $template ? get_post_meta( get_the_ID(), 'align-sidebar', true ) : get_theme_mod('oro_' . $template . '_sidebar_layout', 'right'); $align_arr = ['order-1', 'order-2']; if ( in_array( $template, ['single', 'blog', 'page', 'search', 'archive'] ) ) { return 'right' == $align ? $align_arr : array_reverse($align_arr); } else { return $align_arr; } } /** * Function to get Social icons */ function oro_get_social_icons() { get_template_part('social'); } add_action('oro_social_icons', 'oro_get_social_icons'); /** * Get Custom sizes for 'image' post format */ function oro_thumb_dim( $id, $size ) { $img_array = wp_get_attachment_image_src( $id, $size ); $dim = []; $dim['width'] = $img_array[1]; $dim['height'] = $img_array[2]; return $dim; } function oro_get_site_layout() { echo esc_html( get_theme_mod('oro_site_layout', 'box') ) == 'box' ? 'container' : ''; } add_action('oro_site_layout', 'oro_get_site_layout'); /** * The About Author Section */ function oro_get_about_author( $post ) { ?>
post_author), 96 ); ?>

post_author) ); ?>

post_author) ); ?>
3, "ignore_sticky_posts" => true, "post__not_in" => [get_the_ID()], "category_name" => get_the_category($post)[0]->slug, "orderby" => "rand" ]; $related_query = new WP_Query( $related_args ); if ( $related_query->have_posts() ) : ?> '; break; case '2': return ''; break; case '3': return ''; break; case '4': return ''; break; default: return ''; } } /** * Footer SVG */ function oro_get_footer_svg() { ?>