__section__
default
__description__
This is the main template that creates the /tags webpages.

* tagname = empty if no specific tagname is being listed, otherwise the
	string for that tagname

If tagname is the empty string:
	* displaytype = one of 'active', 'recent', 'all'
	* tagnames = arrayref of tagnames for that display type

If tagname is not the empty string:
	* objects = arrayref of hashrefs with the fields: title, url, created_at

__title__

__page__
tags
__lang__
en_US
__name__
index
__template__
[% PROCESS titlebar title => constants.sitename _ ' Tags' %]

[% IF tagname.length == 0 %]

	[% Slash.createMenu('tagszg', { style => 'oldstyle' }) %]

	[% IF tagnames.size > 0 %]
		<table class="data">
		<tr class="data_head"><th><b>
		[% SWITCH displaytype;
		   CASE 'active'; 'Active'; CASE 'recent'; 'Recent'; CASE 'all'; 'All';
		   CASE DEFAULT; '?'; END %]
		Tags</b></th></tr>
		[% toggle = 1 %]
		[% FOREACH t = tagnames %]
			<tr class="data_hl[% toggle %]">
			<td><a href="[% gSkin.rootdir %]/tags/[% t | strip_paramattr %]">[% t | strip_literal %]</a></td>
			</tr>
			[% toggle = 3 - toggle %]
		[% END %]
		</table>
	[% ELSE %]
		<div>No tags.</div>
	[% END %]

[% ELSE %]

	[% Slash.createMenu('tagszg', { style => 'oldstyle' }) %]

	[% IF objects.size > 0 %]
		<table class="data">
		<tr class="data_head"><th><b>[% tagname | strip_literal %]</b></th></tr>
		[% toggle = 1 %]
		[% FOREACH o = objects %]
			<tr class="data_hl[% toggle %]">
			<td><a href="[% o.url | strip_attribute %]">[% o.title | strip_notags %]</a></td>
			</tr>
			[% toggle = 3 - toggle %]
		[% END %]
		</table>
	[% ELSE %]
		<div>No objects tagged "[% tagname | strip_literal %]"</div>
	[% END %]

[% END %]

__seclev__
10000
__version__
$Id: index;tags;default,v 1.3 2006/04/26 15:40:36 jamiemccarthy Exp $
