Skip to content

Instantly share code, notes, and snippets.

@shubhw12
Created April 8, 2020 08:32
Show Gist options
  • Select an option

  • Save shubhw12/ffb13c42f3046ed2a04b50850f7bed75 to your computer and use it in GitHub Desktop.

Select an option

Save shubhw12/ffb13c42f3046ed2a04b50850f7bed75 to your computer and use it in GitHub Desktop.
Remove Author link from the author card.
add_filter('astra_post_author_output' , 'call_back');
function call_back(){
$author_info_array = sprintf(
'<div class="ast-single-author-box" %2$s itemscope itemtype="https://schema.org/Person">%1$s</div>',
sprintf(
'<div class="ast-author-meta"> <div class="about-author-title-wrapper"> <h3 class="about-author">%1$s</h3> </div> <div class="ast-author-details"> <div class="post-author-avatar">%2$s</div> <div class="post-author-bio"> <a class="url fn n" %6$s rel="author"> <h4 class="author-title" %7$s>%4$s</h4> </a> <div class="post-author-desc">%5$s</div> </div> </div> </div>',
esc_html__( 'About The Author', 'astra-addon' ),
get_avatar( get_the_author_meta( 'email' ), 100 ),
' ',
esc_html( get_the_author() ),
wp_kses_post( get_the_author_meta( 'description' ) ),
astra_attr(
'author-url-info',
array(
'class' => '',
)
),
astra_attr(
'author-name-info',
array(
'class' => '',
)
)
),
astra_attr(
'author-item-info',
array(
'class' => '',
)
),
astra_attr(
'author-desc-info',
array(
'class' => '',
)
)
);
return $author_info_array;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment