<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Building a Website with MODx for Newbies- Part 8: More Ditto</title>
	<atom:link href="http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/feed/" rel="self" type="application/rss+xml" />
	<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/</link>
	<description>Programming blog - Discussions, Tutorials, Resources</description>
	<lastBuildDate>Fri, 30 Jul 2010 13:36:25 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Wesley</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9464</link>
		<dc:creator>Wesley</dc:creator>
		<pubDate>Mon, 14 Jun 2010 23:43:26 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9464</guid>
		<description>Thanks Mary. I&#039;ll dig into the Ditto documentation.

Cheers,
Wesley</description>
		<content:encoded><![CDATA[<p>Thanks Mary. I&#8217;ll dig into the Ditto documentation.</p>
<p>Cheers,<br />
Wesley</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mary</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9463</link>
		<dc:creator>mary</dc:creator>
		<pubDate>Mon, 14 Jun 2010 14:36:45 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9463</guid>
		<description>Wesley
Yes this is totally possible. To explain it in detail will take some time, but one easy way to do this is to use Ditto filters. You would need to add a filter to your Ditto call that would look at say the &quot;published on&quot; date, calculate back whatever number of days you want to show for, and then hide everything prior to that.  So for example, to show only the images published in the last 10 days you would add something like this to your Ditto call  - 
&amp;dateSource=`pub_date` &amp;filter=`pub_date,@EVAL return strtotime(&#039;-10 day&#039;);,3`

Basically, filters take the form &amp;filter=`field,criterion,mode`, and in the case of the example above the field is the published on field, the criteria is set using binding and a PHP statement to take the date minus 10 days, and the mode is 3 (&quot;less than the criterion&quot;).

You can read more about Ditto filters and see the different modes at http://www.pogwatch.com/ditto/ditto-filters.html

My friend Jan who helped me with this should be writing up a more detailed explanation soon, I will link to it here, but if you play around with the code above and read through the info about filters you should be able to string it up fine :)

mary</description>
		<content:encoded><![CDATA[<p>Wesley<br />
Yes this is totally possible. To explain it in detail will take some time, but one easy way to do this is to use Ditto filters. You would need to add a filter to your Ditto call that would look at say the &#8220;published on&#8221; date, calculate back whatever number of days you want to show for, and then hide everything prior to that.  So for example, to show only the images published in the last 10 days you would add something like this to your Ditto call  &#8211;<br />
&amp;dateSource=`pub_date` &amp;filter=`pub_date,@EVAL return strtotime(&#8217;-10 day&#8217;);,3`</p>
<p>Basically, filters take the form &amp;filter=`field,criterion,mode`, and in the case of the example above the field is the published on field, the criteria is set using binding and a PHP statement to take the date minus 10 days, and the mode is 3 (&#8221;less than the criterion&#8221;).</p>
<p>You can read more about Ditto filters and see the different modes at <a href="http://www.pogwatch.com/ditto/ditto-filters.html" >http://www.pogwatch.com/ditto/ditto-filters.html</a></p>
<p>My friend Jan who helped me with this should be writing up a more detailed explanation soon, I will link to it here, but if you play around with the code above and read through the info about filters you should be able to string it up fine <img src='http://codingpad.maryspad.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>mary</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Wesley</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9455</link>
		<dc:creator>Wesley</dc:creator>
		<pubDate>Fri, 11 Jun 2010 17:58:18 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9455</guid>
		<description>Thanks as always for the really superb tuts. Just great.

I have a question re: Ditto -- is it be possible to aggregate content that displays for a certain period of time? Specifically, I&#039;d like to use Ditto to create a &#039;recent images&#039; aggregation, and to make this list dynamic in as much as it will automatically include new images while discarding images that reach a certain age (i.e. that hit a prescribed time limit keyed off of the initial publish date).

I&#039;m just getting into MODx and still have a ton of reading to do, so apologies if this is something discussed elsewhere.

Thank again for this content -- it is very quickly making me a fan of MODx (and the coding pad)!</description>
		<content:encoded><![CDATA[<p>Thanks as always for the really superb tuts. Just great.</p>
<p>I have a question re: Ditto &#8212; is it be possible to aggregate content that displays for a certain period of time? Specifically, I&#8217;d like to use Ditto to create a &#8216;recent images&#8217; aggregation, and to make this list dynamic in as much as it will automatically include new images while discarding images that reach a certain age (i.e. that hit a prescribed time limit keyed off of the initial publish date).</p>
<p>I&#8217;m just getting into MODx and still have a ton of reading to do, so apologies if this is something discussed elsewhere.</p>
<p>Thank again for this content &#8212; it is very quickly making me a fan of MODx (and the coding pad)!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike  Li</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9392</link>
		<dc:creator>Mike  Li</dc:creator>
		<pubDate>Mon, 24 May 2010 02:30:44 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9392</guid>
		<description>Hi, Mary,

Thanks a lot for your nice work.

I have one question, i&#039;m using :
[!Ditto? ............ &amp;orderBy=`pub_date DESC`  !]
But i do not want to use the pub_date, can i use the Page IDs for sortting?

Hope can get your kindly response, TIA.</description>
		<content:encoded><![CDATA[<p>Hi, Mary,</p>
<p>Thanks a lot for your nice work.</p>
<p>I have one question, i&#8217;m using :<br />
[!Ditto? ............ &amp;orderBy=`pub_date DESC`  !]<br />
But i do not want to use the pub_date, can i use the Page IDs for sortting?</p>
<p>Hope can get your kindly response, TIA.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Angie</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9388</link>
		<dc:creator>Angie</dc:creator>
		<pubDate>Fri, 21 May 2010 15:47:19 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9388</guid>
		<description>Hi Mary, 

That is actually a big help, because I&#039;ve been on the verge of tears trying to make this work. At least now I know that I need to go another route. If all else fails, I know I can just go with good old fashioned html!

Thanks so much for everything! Your tuts have helped me build the rest of my site. This is the very last thing I need to figure out. =)</description>
		<content:encoded><![CDATA[<p>Hi Mary, </p>
<p>That is actually a big help, because I&#8217;ve been on the verge of tears trying to make this work. At least now I know that I need to go another route. If all else fails, I know I can just go with good old fashioned html!</p>
<p>Thanks so much for everything! Your tuts have helped me build the rest of my site. This is the very last thing I need to figure out. =)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mary</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9387</link>
		<dc:creator>mary</dc:creator>
		<pubDate>Fri, 21 May 2010 15:37:56 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9387</guid>
		<description>Ah, you&#039;re using MaxiGallery.  I&#039;m not 100% sure how that would work since I have never used MaxiGallery mixed with Ditto in this way.  I would recommend you ask on the forums and see if someone has a similar setup. 

I suspect there may be an easier way to accomplish what you&#039;re trying to do, but I am honestly not well versed enough with MaxiGallery to guide you.

Sorry I can&#039;t help out more.
mary</description>
		<content:encoded><![CDATA[<p>Ah, you&#8217;re using MaxiGallery.  I&#8217;m not 100% sure how that would work since I have never used MaxiGallery mixed with Ditto in this way.  I would recommend you ask on the forums and see if someone has a similar setup. </p>
<p>I suspect there may be an easier way to accomplish what you&#8217;re trying to do, but I am honestly not well versed enough with MaxiGallery to guide you.</p>
<p>Sorry I can&#8217;t help out more.<br />
mary</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Angie</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9383</link>
		<dc:creator>Angie</dc:creator>
		<pubDate>Thu, 20 May 2010 16:14:00 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9383</guid>
		<description>Hi Mary, 

I&#039;m going to *attempt* to explain what I&#039;m looking at, lol! 

My template chunk is the same as yours, but I removed the introtext and the read more... stuff, since I&#039;m just using all pictures. 

My Parent page, named Fan Art, shows this: (minus some coding, so it will hopefully show up here)

!MaxiGallery display=`embedded` embedtype=`slimbox` pics_per_row=`3` max_thumb_size=`273` max_pic_size=`700` thumb_use_dropshadow=`1`!

!Ditto? parents=`55` paginate=`1` display=`3` tpl=`FanartTemplate` paginateAlwaysShowLinks=`1` !

div id=&quot;ditto_pages&quot;  [+previous+] [+pages+] [+next+] Page [+currentPage+] of [+totalPages+] /div 

The children are named Fan Art 2 and Fan Art 3. I didn&#039;t put anything but the maxigallery code in those. (I hope that&#039;s right!) When I go to the parent Fan Art, this is what I get. 

Fan Art 3 (link)
Fan Art 2 (link)
 Page 1 of 1 (no links)

Nothing shows up at the bottom of the children pages. 

I&#039;m trying to get the 1,2,3, etc at the bottom of all pages that will link to each other. I&#039;m assuming that it has to do something with the +pagetitle+ in the template, but I don&#039;t know what to do otherwise. 

Thank you so much for helping out. =)</description>
		<content:encoded><![CDATA[<p>Hi Mary, </p>
<p>I&#8217;m going to *attempt* to explain what I&#8217;m looking at, lol! </p>
<p>My template chunk is the same as yours, but I removed the introtext and the read more&#8230; stuff, since I&#8217;m just using all pictures. </p>
<p>My Parent page, named Fan Art, shows this: (minus some coding, so it will hopefully show up here)</p>
<p>!MaxiGallery display=`embedded` embedtype=`slimbox` pics_per_row=`3` max_thumb_size=`273` max_pic_size=`700` thumb_use_dropshadow=`1`!</p>
<p>!Ditto? parents=`55` paginate=`1` display=`3` tpl=`FanartTemplate` paginateAlwaysShowLinks=`1` !</p>
<p>div id=&#8221;ditto_pages&#8221;  [+previous+] [+pages+] [+next+] Page [+currentPage+] of [+totalPages+] /div </p>
<p>The children are named Fan Art 2 and Fan Art 3. I didn&#8217;t put anything but the maxigallery code in those. (I hope that&#8217;s right!) When I go to the parent Fan Art, this is what I get. </p>
<p>Fan Art 3 (link)<br />
Fan Art 2 (link)<br />
 Page 1 of 1 (no links)</p>
<p>Nothing shows up at the bottom of the children pages. </p>
<p>I&#8217;m trying to get the 1,2,3, etc at the bottom of all pages that will link to each other. I&#8217;m assuming that it has to do something with the +pagetitle+ in the template, but I don&#8217;t know what to do otherwise. </p>
<p>Thank you so much for helping out. =)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mary</title>
		<link>http://codingpad.maryspad.com/2009/05/01/building-a-website-with-modx-for-newbies-part-8-more-ditto/comment-page-1/#comment-9380</link>
		<dc:creator>mary</dc:creator>
		<pubDate>Thu, 20 May 2010 12:15:29 +0000</pubDate>
		<guid isPermaLink="false">http://codingpad.maryspad.com/?p=760#comment-9380</guid>
		<description>Angie
I assume you&#039;re using Ditto? What does your Ditto call and your pagination call look like?  

mary</description>
		<content:encoded><![CDATA[<p>Angie<br />
I assume you&#8217;re using Ditto? What does your Ditto call and your pagination call look like?  </p>
<p>mary</p>
]]></content:encoded>
	</item>
</channel>
</rss>
