Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2005-11-23 17:57:44

rsilletti
Moderator
From: Spokane WA
Registered: 2004-04-28
Posts: 707

Re: Archive lists by month (section, category, etc) with 4.0.2

Plugin <a href=“http://textcastle.com/file_download/29”>section_custom</a>, or you can just manually define a list of links with <code><a href=…index.php?s=sectionname”>sectionname</a></code>.

Offline

#14 2005-12-03 13:42:38

Dufresne
Member
Registered: 2005-09-19
Posts: 22

Re: Archive lists by month (section, category, etc) with 4.0.2

Zem, thanks for the FAQ.

Works a treat.

Offline

#15 2005-12-03 14:06:31

ortem
New Member
Registered: 2005-11-27
Posts: 5

Re: Archive lists by month (section, category, etc) with 4.0.2

this is very helpful… thank you

Offline

#16 2005-12-03 14:39:27

Dufresne
Member
Registered: 2005-09-19
Posts: 22

Re: Archive lists by month (section, category, etc) with 4.0.2

Just in case this comes in handy for other people, you can use this technique for events as well.

All you need to do is add the time=“future” to the article custom tage like so:

<code><txp:article_custom limit=99999 form=“monthly_article” section=“events” time=“future” /></code>

And voila! a list of upcoming events by year and month.

As i want to archive news and events i’ve done the following on the archive_list page templage
<code>
<txp:if_section name=“events_archive”>
<txp:article_custom limit=99999 form=“monthly_article” section=“events” time=“future” />
</txp:if_section>
<txp:if_section name=“news_archive”>
<txp:article_custom limit=99999 form=“monthly_article” section=“news” />
</txp:if_section>
</code>

Hope this comes in useful

Offline

#17 2005-12-05 18:02:05

rsilletti
Moderator
From: Spokane WA
Registered: 2004-04-28
Posts: 707

Re: Archive lists by month (section, category, etc) with 4.0.2

Dufresne: This is a nice example, you might repost it under its own title, it would make it easier for folks to find.

Offline

#18 2005-12-15 07:52:26

shafi707
Member
Registered: 2005-12-01
Posts: 17
Website

Re: Archive lists by month (section, category, etc) with 4.0.2

Yes..this is what I was looking for..


http://tech-resource.info

Offline

#19 2005-12-31 06:57:08

Anark
Member
Registered: 2004-08-14
Posts: 101

Re: Archive lists by month (section, category, etc) with 4.0.2

Thanks, Zem!

As it is, the Year and Month headings are marked up in H2 and H3 tags respectively but the permalinks lack any markup except for the break tags.

If I take the advice given in the FAQ and use li tags in the form and ul tags around the txp:article_custom tag on the page, I end up with everything, including the headings, inside one all-embracing ul tag, which isn’t what I wanted. I wanted a new list for every month.

How do I mark up the permalinks either as a list or as lines in a paragraph?

Offline

#20 2005-12-31 17:06:07

takshaka
Archived Plugin Author
From: Below the Manson-Nixon line
Registered: 2004-06-02
Posts: 97
Website

Re: Archive lists by month (section, category, etc) with 4.0.2

Use something like this as your article form:

<code>
<txp:if_first_article>
<ul class=“empty”>
</txp:if_first_article>
<txp:if_different>
<!— <txp:posted format=”%B” /> —>
</ul>
</txp:if_different>
<txp:if_different>
<h2><txp:posted format=”%Y” /></h2>
</txp:if_different>
<txp:if_different>
<h3><txp:posted format=”%B” /></h3>
<ul>
</txp:if_different>
<li><txp:permlink><txp:title /></txp:permlink></li>
<txp:if_last_article>
</ul>
</txp:if_last_article>
</code>

You’ll end up with an empty UL at the beginning, which isn’t ideal, but you can style it away.

Offline

#21 2006-01-01 02:33:00

Anark
Member
Registered: 2004-08-14
Posts: 101

Re: Archive lists by month (section, category, etc) with 4.0.2

Cool. Thanks!

Offline

#22 2006-01-01 09:49:32

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,101
Website GitHub Mastodon Twitter

Re: Archive lists by month (section, category, etc) with 4.0.2

one of the cool features rss_superarchive has is the ability to also list articles by section/category. A feature indispensable for those who wish to create site maps. Can someone point towards a method with wich this can be achieved without the rss_suparchive?


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#23 2006-01-01 15:49:44

thebombsite
Archived Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: Archive lists by month (section, category, etc) with 4.0.2

You could follow my little explanation. Including “sections” would be similar to the category method I have explained but would also be similar to the year/month method in that there are 2 “if_different” calls.

Last edited by thebombsite (2007-01-27 23:05:07)


Stuart

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#24 2006-01-03 08:10:51

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,101
Website GitHub Mastodon Twitter

Re: Archive lists by month (section, category, etc) with 4.0.2

thanks stu
Your explanation helped me loads. Did it slightly differently but the kick start was definitely provided in your text.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

Board footer

Powered by FluxBB