Last active
January 12, 2020 20:52
-
-
Save imfaisalkh/7dfabc07d13dd221ba5b2ae2e0a3b6b4 to your computer and use it in GitHub Desktop.
Capstone - Add an Excerpt to Resume Master Listings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'resume_listing_meta_end', 'capstone_add_resume_auto_excerpt', 99); | |
function capstone_add_resume_auto_excerpt() { | |
echo '<li class="auto-excerpt" data-full-width>'; | |
$resume_desc = apply_filters( 'the_resume_description', get_the_content() ); | |
echo '<label>'. esc_html__('Excerpt:', 'capstone') .'</label>'; | |
echo wp_kses_post(substr($resume_desc, 0, 200)) .'...'; | |
echo '</li>'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment