Hello Patrick,
Thanks for writing in!
The given code only works for the Portfolio post type archive:
add_action( 'x_before_view_global__index', 'portfolio_short_desc' );
function portfolio_short_desc() {
if(is_post_type_archive( 'x-portfolio' )){
echo "<p>Short Description</p>";
}
}
To make this work in the portfolio page, you will have to replace is_post_type_archive( 'x-portfolio' )
with is_page_template( 'template-layout-portfolio.php' )
therefore the final code would be:
add_action( 'x_before_view_global__index', 'portfolio_short_desc' );
function portfolio_short_desc() {
if( is_page_template( 'template-layout-portfolio.php' ) ){
echo "<p>Short Description</p>";
}
}
Please note that the code provided above serves as a guide only and is to help you in getting started so implementing it and maintaining the code will be out of our support scope and for further maintenance for new possible versions of the theme that may cause the customization to break, you will need to hire a developer.
Notice: Custom coding is outside the scope of our support. Issues that might arise from the use of custom code and further enhancements should be directed to a third party developer.
Best Regards.