WordPress.org

Support

Support » Plugins and Hacks » Yoast SEO » Get meta-description with limited characters

Get meta-description with limited characters

  • Hi!

    I need show in homepage the meta-description of three pages. I got it partially with:

    <?php
    $yoast_meta = get_post_meta($post->ID, '_yoast_wpseo_metadesc', true);
    if ($yoast_meta) {
    echo '<p>'.$yoast_meta.'</p>';
    }
    ?>

    I need to limit the number of characters, because I need to ensure that the texts have exactly the same size.

    Is it possible?

    Thanks,

    Danilo

    https://wordpress.org/plugins/wordpress-seo/

  • The topic ‘Get meta-description with limited characters’ is closed to new replies.
Skip to toolbar