{include file="$blogtemplate/header.template"}
	<div><!-- end header -->
		{assign var=metadata value=$resource->getMetadataReader()}
		{assign var=updated value=$resource->getTimestamp()}
		
		<h2>
			Filename: {$resource->getFileName()} ({$metadata->getRoundedSize()}) | 
			{$locale->tr("created")} {$locale->formatDate($updated,"%d %B, %Y")} | 
			<a href="{$url->resourceDownloadLink($resource)}">{$locale->tr("download")}</a>
		</h2>
		<h3>{$resource->getFileName()}</h3>
		<br/>
		    
		<p>{$resource->getDescription()}</p>
		{if $resource->isImage()}
		<center><img src="{$url->resourceMediumSizePreviewLink($resource)}" alt="{$resource->getFileName()}, {$metadata->getRoundedSize()}" /></center>
	{else}
		<a href="{$url->resourceDownloadLink($resource)}">
		
		{* show some information about the file *}
		{if $resource->isSound()}
			<img alt="Sound" src="{$url->getUrl("/imgs/sound.gif")}" height="64" width="64" style="border:0px;" /><br/>
			{$resource->getFileName()}
			</a><br/>     
			{$locale->tr("format")}: {$metadata->getFormat()|upper}<br/>
			{$locale->tr("length")}: {$metadata->getLengthString()}<br/>
			{$locale->tr("sample_rate")}: {$metadata->getSampleRate()} Khz
		{elseif $resource->isVideo()}
			<img alt="Sound" src="{$url->getUrl("/imgs/video.gif")}" height="64" width="64" style="border:0px;" /><br/>
			{$resource->getFileName()}
			</a><br/>
			{$locale->tr("format")}: {$metadata->getFormat()|upper}<br/>
			{$locale->tr("size")}: {$metadata->getHeight()} x {$metadata->getWidth()}<br/>
			{$locale->tr("length")}: {$metadata->getLengthString()}<br/>
			{$locale->tr("video_codec")}: {$metadata->getVideoCodec()}<br/>
			{$locale->tr("audio_codec")}: {$metadata->getAudioCodec()}
		{elseif $resource->isZip()}
			<img alt="Sound" src="{$url->getUrl("/imgs/compressed.gif")}" height="64" width="64" style="border:0px;" /><br/>
			{$resource->getFileName()}
			</a><br/>
			{$metadata->getTotalFiles()} {$locale->tr("files")}<br/>
			{$locale->tr("uncompressed_size")}: {$metadata->getRoundedUncompressedSize()}
	{else}
		<img alt="Sound" src="{$url->getUrl("/imgs/file.gif")}" height="64" width="64" style="border:0px;" /><br/>
		{$resource->getFileName()}
		</a>    
		{/if}
	{/if}
	<br/>
	<p>
		{assign var=album value=$resource->getAlbum()}
   		{if $prevresource}<a href="{$url->resourceLink($prevresource)}">&laquo;</a> | {/if}
   		<a href="{$url->albumLink($album)}">{$locale->tr("back")}</a>
   		{if $nextresource}| <a href="{$url->resourceLink($nextresource)}">&raquo;</a>{/if}  
	</p>



{include file="$blogtemplate/footer.template"}
