Second level of archive #134
-
I am trying to build something in which I generate grouped archives per year and per month, like the following I can click on the year to see all blog posts for that year. If I click on the month, I will see all blog posts for that month of that year. This is the way I do the year, and which creates my index as I want it
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
To set you off in the right direction, one thing you could look at is string interpolation. Anything after the
You would likely have to change your ArchiveDestination key too, but I feel this may get you closer to what you're looking for. Also, I don't really know the api of $"{GetDateTime("date"): yyyy-MM}" // 2022-02 I'm sure you could also make that |
Beta Was this translation helpful? Give feedback.
-
I keep meaning to work up an example and keep running out of time. I'll still do that and post it here, but in the meantime I think the key to what you want is two archives. Do one archive for month-by-month (and include the year in the key as @Foxtrek64 mentioned) and then another archive for year-by-year. Then in the archive list template for the year-by-year archive, group the archive documents by month and add a link to where you know the month-by-month archive summary will be written. Does that make sense? |
Beta Was this translation helpful? Give feedback.
I keep meaning to work up an example and keep running out of time. I'll still do that and post it here, but in the meantime I think the key to what you want is two archives. Do one archive for month-by-month (and include the year in the key as @Foxtrek64 mentioned) and then another archive for year-by-year. Then in the archive list template for the year-by-year archive, group the archive documents by month and add a link to where you know the month-by-month archive summary will be written.
Does that make sense?