<{capture name="title"}><{$page->getHeadline()}><{/capture}>

<div class="page">
	<h1><a href="<{$page->getUrl()|escape}>"><{$page->getHeadline()|escape}></a></h1>

	<{assign var="images" value=$page->getImages()}>

	<{if $images}>
		<div class="pageimages">

			<{if $images|@count == 1}>

				<{section name="i" loop=$images}>
					<a href="<{$images[i]->getSrc(800, 800, 'fit')}>" rel="lightbox"><img src="<{$images[i]->getSrc(300, 300, 'fit')}>" alt="" <{$images[i]->getHtmlSize(300, 300, 'fit')}>/></a>
				<{/section}>

			<{elseif $images|@count < 3}>

				<{section name="i" loop=$images}>
					<a href="<{$images[i]->getSrc(800, 800, 'fit')}>" rel="lightbox"><img src="<{$images[i]->getSrc(150, 150, 'box')}>" alt="" <{$images[i]->getHtmlSize(150, 150, 'box')}>/></a>
				<{/section}>

			<{elseif $images|@count < 6}>

				<{section name="i" loop=$images}>
					<a href="<{$images[i]->getSrc(800, 800, 'fit')}>" rel="lightbox"><img src="<{$images[i]->getSrc(100, 100, 'box')}>" alt="" <{$images[i]->getHtmlSize(100, 100, 'box')}>/></a>
					<{if $smarty.section.i.index%3 == 2}><br/><{/if}>
				<{/section}>

			<{else}>

				<{section name="i" loop=$images}>
					<a href="<{$images[i]->getSrc(800, 800, 'fit')}>" rel="lightbox"><img src="<{$images[i]->getSrc(50, 50, 'box')}>" alt="" <{$images[i]->getHtmlSize(50, 50, 'box')}>/></a>
					<{if $smarty.section.i.index%3 == 2}><br/><{/if}>
				<{/section}>

			<{/if}>

		</div>
	<{/if}>

	<{$page->getText()}>

</div>