{** display a minibrowser-item (a folder or a file) **}
<a	href="#;"
	class="minibrowserItem {if $is_file}minibrowserFile{else}minibrowserFolder{/if}"
	{if $is_file}
		onclick="
				var control=$$('{$targetInput}');
				if(control){ldelim}
					control[0].value='{$path}{$name}';
					var eventName=$(control[0]).readAttribute('id');
					Controls.getGlobal('focus').onChange(null,eventName,'shortdelay');

					$('overDiv').hide();
				{rdelim}else{ldelim}
					// this should never happen anyway
					alert('Technical error. The file cannot be selected');
				{rdelim}
				return false;"
	{else}
		onclick="showMinibrowser('{$target}','{$filter}','{$path}/{$name}','{$targetInput}');return false;"
	{/if}
>
	<div>

		{if is_array($item) and $item['is_file']}
			<img src="{$smarty.const.SMARTY_BLANKGIF}" alt="" align="absmiddle" class="imgIcon {$type|default:'icon-invalidFile'}"
				tooltip="{$name}"
			/>
		{else}
			<img src="{$smarty.const.SMARTY_BLANKGIF}" alt="" align="absmiddle" class="imgIcon icon-folder"
				tooltip="{$name}"
			/>
		{/if}

		{$name|truncate:18:'..'}
	</div>
</a>