';
}
}
add_action( 'wp_head', 'author_portfolio_pingback_header' );
if ( ! function_exists( 'author_portfolio_comment_list' ) ) :
/**
* Template for comments and pingbacks.
*
* Used as a callback by wp_list_comments() for displaying the comments.
*
* @since Shape 1.0
*/
function author_portfolio_comment_list( $comment, $args, $depth ) {
extract( $args, EXTR_SKIP );
if ( 'div' == $args['style'] ) {
$tag = 'div';
$add_below = 'comment';
} else {
$tag = 'li';
$add_below = 'div-comment';
}
?>
< id="comment-">
1 ) {
$numberingtext = 'posts';
} else {
$numberingtext = 'post';
}
$userposts = esc_html__( 'The author has %1$s %2$s', 'author-portfolio' );
printf( $userposts, $userpost_count, $numberingtext );
?>
get( 'AuthorURI' );
}
/**
* Masonry Layout Control
*/
function author_portfolio_masonry_layout_control(){
$get_masonry_layout = get_theme_mod('active_masonry_layout', true);
if (true === $get_masonry_layout) {
return ' masonry_active';
}
return '';
}
/**
* Limit Excerpt length
*/
function author_portfolio_post_excerpt_limit( $length ) {
$length = get_theme_mod('post_loop_excerpt_limit', 42);
return $length;
}
add_filter( 'excerpt_length', 'author_portfolio_post_excerpt_limit', 999 );
/**
* Social Links
*/
function author_portfolio_social_links(){
$defaults_links = array(
[
'social_icon_class' => 'fa fa-facebook',
'social_link' => 'https://facebook.com',
],
[
'social_icon_class' => 'fa fa-twitter',
'social_link' => 'https://twitter.com',
],
[
'social_icon_class' => 'fa fa-pinterest',
'social_link' => 'https://pinterest.com',
],
[
'social_icon_class' => 'fa fa-instagram',
'social_link' => 'https://instagram.com',
],
[
'social_icon_class' => 'fa fa-medium',
'social_link' => 'https://medium.com',
],
);
$social_links = get_theme_mod('social_links', $defaults_links);
foreach( $social_links as $social_link ) :
?>
is_search && $post_type == 'books-gallery' )
{
return locate_template('search-books.php'); // redirect to archive-search.php
}
return $template;
}
add_filter('template_include', 'author_portfolio_template_chooser');
add_action('admin_menu', 'author_portfolio_personalize');
function author_portfolio_personalize(){
remove_submenu_page( 'sb-instagram-feed', 'sb-instagram-feed-about' );
}
add_action('sbi_before_feed', 'author_portfolio_sbi_before_feed');
function author_portfolio_sbi_before_feed(){
?>