Viewing 19 posts - 1 through 19 (of 19 total)
  • Author
    Posts
  • #1434630

    nothing in the from works!! newest enfold theme. please help…

    #1434646

    Hey Christian,
    It depends on many factors, try this thread
    If this doesn’t help them include a admin login and link to your page so we can examine.

    Best regards,
    Mike

    #1434651

    all that i have tested on masonry!!! is doeswnt work…

    thats the site http://relaunch.lichtfilm.com/de/vod/

    #1434653

    Hi,
    Thanks for the link to your page, it looks like each item is showing no words in the excerpt, only a “more” link, your titles show words but the word limits don’t work on titles, perhaps this is why it is not working as you thought.

    Best regards,
    Mike

    #1434654

    i look in the original av-helper-masonry.php and class-avia-mansonry.php and there i found that not the exceprt is used! the $entry->post_content

    #1434655

    t have testet some code. now the orginal is back

    #1434656

    Hi,
    Now I see there are excerpts showing, so it seems that one of these snippets was working, right?

    Best regards,
    Mike

    #1434657

    there is no shorten the length!

    #1434658

    only the first and second examples are relevant! where i use the field excerpt

    #1434659
    This reply has been marked as private.
    #1434660

    Hi,
    Please note that this depends on many factors, please fully explanin what you are trying to achieve, are you going to be using manual excerpts on your items? Do you want a read more button? what limit do you want? Some of your items don’t use manual excerpts, so all of your items need to be the same.

    Best regards,
    Mike

    #1434662

    i want shorten the excerpt for manual excerpts

    #1434664

    Hi,
    How long? Do you want read more buttons?

    Best regards,
    Mike

    #1434665

    i want a code for this for the functions file
    … so i can change it

    #1434667

    Hi,
    I added this to your child theme functions.php

    function custom_excerpt_setting(){
    ?>
    <script>
    (function($){
        function trimByWord(sentence,wordcount = 10) {
            var result = sentence;
            var resultArray = result.split(" ");
            if(resultArray.length > wordcount){
            resultArray = resultArray.slice(0, wordcount);
            result = resultArray.join(" ") + "...";
            }
            return result;
        }
        $(document).ready(function(){
            $('.av-masonry-entry-content').each(function() {
                 $(this).text(function(index, currentText) {
                    return trimByWord(currentText);
                 });
            });
        });
    })(jQuery);
    </script>
    <?php
    }
    add_action('wp_footer', 'custom_excerpt_setting');

    please clear your browser cache and check.

    Best regards,
    Mike

    #1434670

    thanks! that works. Is it possible without javascript?

    #1434672

    Hi,
    Glad that this helped, I didn’t find any other working solution, the manual excerpts are not as easy.

    Best regards,
    Mike

    #1434673

    thanks! have a nice evenning.

    #1434675

    Hi,
    Glad we were able to help, if you have any further questions please create a new thread and we will gladly try to help you. Thank you for using Enfold.

    Best regards,
    Mike

Viewing 19 posts - 1 through 19 (of 19 total)
  • The topic ‘Shorten masonry blogpost excerpt length’ is closed to new replies.