• Ok guys, i use WordPress for a while now, but just starting to make my own themes.

    I don’t know how excerpt exactly work, but maybe i must use it. I searched on Google and this about this issue but none worked for me.

    Question:
    I want to limit the number of words shown on the title. I did it with the “Content and Excerpt Word Limit” on the content, but the same does not work on the Title. Now i use some char limiter function but i want to have limit in words.

    Can someone help me? Searching for days now..

    Thanks

Viewing 1 replies (of 1 total)
  • limit the number of charecters in a title

    <?php if (strlen($post->post_title) > 35) {
    echo substr(the_title($before = '', $after = '', FALSE), 0, 35) . '...'; } else {
    the_title();
    } ?>
Viewing 1 replies (of 1 total)
  • The topic ‘HowTo: Limit title words’ is closed to new replies.