how to set # of characters that appear

Discussion in 'GeoCraft WordPress Theme' started by markbringitlocal, Mar 29, 2013.

Thread Status:
Not open for further replies.
  1. markbringitlocal

    markbringitlocal New Member

    Joined:
    Jan 16, 2013
    Messages:
    5
    Likes Received:
    0
    Hi,

    Is there somewhere I can set the number of characters that appear in the home page listing description before the 'read more' link to the full listing?
    thanks!
     
  2. Gourav

    Gourav Support Staff

    Joined:
    Oct 19, 2012
    Messages:
    7,728
    Likes Received:
    207
    Go to functions.php present in your theme directory and add the code given below

    Code:
    function custom_excerpt_length( $length ) {
        return 200;
    }
    add_filter( 'excerpt_length', 'custom_excerpt_length', 999 );
    Sending image for reference

    [​IMG]

    Adjust "return" value as per your requirements.
     
  3. markbringitlocal

    markbringitlocal New Member

    Joined:
    Jan 16, 2013
    Messages:
    5
    Likes Received:
    0
    perfect. thanks very much.
     
Thread Status:
Not open for further replies.

Share This Page