Im trying to use Low Yearly Archives to show a list months with a list to an individual month of articles.

I also want to show a list of years excluding the current year so the page will look something like this:

Jan Feb

2014 2013 2012

Ive had this running on earlier versions of EE but can't get it join on 2.9

Here is the code:


$year = $this->EE->localize->decode_date("%Y", $this->EE->localize->now);


{exp:low_yearly_archives channel="news" start_month="1" status="not closed" sort="desc" show_future_entries="no" start_year="<?=$year?>" end_year="<?=$year?>" dynamic="yes"}
{if num_entries > 0}
<a href="{site_url}news/archive/{year}/{month_num}/" title="{num_entries} entries in {month} {year}">{month}</a> | {num_entries}

{exp:low_yearly_archives channel="news" status="not closed" sort="desc" end_year="<?=$year-1?>" dynamic="no"}
{if year == "<?=$year?>"}
{if entries_in_year > 0}
<a href="{site_url}news/year/{year}/" title="{entries_in_year} entries in {year}"><strong>{year}</strong></a>

Im sure it has something to due with the php part but I can't get it working.

1 Answer 1


I figured it out. I needed to change: decode_date to format_date

$year = $this->EE->localize->format_date("%Y", $this->EE->localize->now);

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.