badget

Biggest Sale! Special Offer!

Get 30% discount on all of our single themes with this coupon code: #30%SALE

Hurry up! *Limited time offer*

How to display text from the Excerpt field of a Page in the Service Widget

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #9243
    Jeff
    Participant

    We are using the Attitude Pro theme.

    I am using the Services Widgets on the Business home page and the article full text displays with a read-more link, as expected. Is it possible to enter text in the Page editor’s Excerpt field and have that display in the Service Widget instead? I tried this and could not make it work.

    #9269

    Hi Jeff

    You add the text inside excerpt. If you add text inside excerpt then it will display the excerpt text. If excerpt is blank then it will display from the editor.

    By default, excerpt length is set to 55 words. To change excerpt length to 20 words using excerpt_length filter, add the following code to functions.php file in your theme:

    e.g:- `function custom_excerpt_length( $length ) {
    return 20;
    }
    add_filter( ‘excerpt_length’, ‘custom_excerpt_length’, 999 );`

    But you need to make the child theme before using it. Because while updating our new version all your setting would be lost.

    https://codex.wordpress.org/Child_Themes

    If it is really hard to fix it then we have this facility in our attitude-pro version.

    Regards

    Sunil

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.