Photo excerpt (nearly)

Home Forums Calendar Products Events Calendar PRO Photo excerpt (nearly)

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #998253
    John Paul
    Participant

    Hi, I finally managed to get the excerpt redcued in the photo view…..the std wp codex in the function file was nto working..so I copied from another discussion and used the following code in my photo single_event.php file

    <!– Event Content –>
    <?php do_action( ‘tribe_events_before_the_content’ ) ?>
    <div class=”tribe-events-list-event-description tribe-events-content description entry-summary”>

    <?php
    $excerpt = get_the_excerpt();
    $excerpt = substr( $excerpt , 0, 100);
    echo $excerpt;
    ?>
    </div>

    and bingo …it worked!!! however this seems to use character count………what can I change to enable it to use word count..?

    all the best

    #998451
    Brian
    Member

    Hi,

    Thanks for using our plugins. I can try to help out here, but we do not have a word count function and not sure if WordPress does either.

    I did a quick search and found this snippet that you might be able to adapt to limit the excerpt by words not characters:

    http://snipplr.com/view/12987/limit-words-in-a-string/

    Cheers!

    #1002867
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Photo excerpt (nearly)’ is closed to new replies.