We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 121
    • 36 Posts
    Please help,

    This is driving me crazy, I have read all the posts relating to truncLen and just cannot get the latest news story on my homepage to limit to 20 words (it has to due to limited space).

    The homepage is looking in two folders for the latest published story, the actual latest published story is showing on my homepage ok, it is just not limited to 20 words.

    Here is my chunk, it’s called "latestNewsChunk"

    <p class="headline"><a href="[~[+id+]~]" title="View story">[+title+]</a></p>
    <p class="date">[+date+]</p>
    <p class="summary">[+introtext+]</p>
    


    Here is the call from my template.

    [[Ditto? &startID=`37,20` &summarize=`1` &total=`1` &tpl=`latestNewsChunk` &trunc=`1` &truncLen=`20`!]]
    


    Now, I have read on other posts to use the [+summary+], but what exactly is this field in the manager? All I can see is the content (html) section, the Summary (introtext) and custom TV’s I have made.

    Please can someone help, I’m going crazy with this rolleyes

    Thanks in advance.
      • 1788
      • 1,103 Posts
      Quote from: 4hero at Apr 01, 2008, 03:43 PM

      Now, I have read on other posts to use the [+summary+], but what exactly is this field in the manager? All I can see is the content (html) section, the Summary (introtext) and custom TV’s I have made.

      Please can someone help, I’m going crazy with this rolleyes

      Thanks in advance.

      http://wiki.modxcms.com/index.php/PHx/CustomModifiers#phx:word_limit
        • 121
        • 36 Posts
        WooHoo, thanks antey!! It now works beautifully grin
          • 18397
          • 3,250 Posts
          Here is more information on the summary extender, activated in Ditto 2 with &extenders=`summary`
          http://ditto.modxcms.com/extenders/summary.html