-
- 97 Posts
Sounds good, I’m glad you got it working for your needs. This conversation has made me think of some possible improvements for this snippet. I never use MODx’s description field, and I have another snippet I wrote that will pull the title or long title into the title tag. But everyone works differently so I’d like to make this snippet have a few more parameters to use as options (like being able to pull in a document variable instead of having to use a template variable).
James
-
- 480 Posts
Adrian Lawley: www.adrianlawley.com
-
- 70 Posts
Hi,
Just found DynamicDescription and was wondering if there’s any way that it could be used in conjunction with Ditto? I have a very simple news page that displays the title and summary of a post, along with a ’read more’ link to the post itself, but I can’t find a way of achieving exactly what I want, which is a ’tidy’ summary.
I’d rather not use [+introtext+], as it’s another thing thing the client has to type in - I’d rather the summary was generated from the main content of the post. The ’summary’ extender in the Ditto call sort of works, but I’m not keen to keep using it if it has been superseded, and also it sets the limit at x characters, which looks a bit messy if a word is cut in half.
DynamicDescription looks really good as it limits to x words, but I’m not sure how to get it working with the parent page that contains the post summaries/links, as I need it to reference the document ids of each of the child pages.
Has anybody done anything similar or have any ideas about this?!
-
- 70 Posts
Sorry, just found that it can be done! The PHx word_limit modifier will do it, if anyone else is interested.