<div dir="ltr"><div dir="ltr"><div dir="ltr"><div><a href="https://www.pmwiki.org/wiki/PmWiki/PageListTemplates">Page list templates</a> are a powerful and useful mechanism in PmWiki.</div><div><br></div><div>I've got a use case where I have many page names prefixed by date - i.e. "yyyy-mm-dd etc"</div><div><br></div><div>I would like to group then into years, e.g. by something like this</div><div><br></div><div>(:template first {(substr {=$Name} 0 4)}:)</div><div><br></div><div>any suggestions on how I can achieve this.</div><div>As you may surmise the above does not work</div><div><br></div><div>thanks</div><div><br></div><div>Simon</div><div><br></div><div>PS note interestingly I can do this</div><div><div>(:template defaults year='{(substr {=$Name} 0 4)}':)</div></div><div>and use {$$year} successfully in the page list template</div></div></div></div>