{* * search.tpl * gitphp: A PHP git repository browser * Component: Search view template * * Copyright (C) 2009 Christopher Han *} {include file='header.tpl'} {* Nav *} {include file='title.tpl' titlecommit=$commit} {* Print each match *} {foreach from=$results item=result} {assign var=resulttree value=$result->GetTree()} {/foreach} {if $hasmore} {/if}
{if $result->GetAge() > 60*60*24*7*2}{$result->GetCommitterEpoch()|date_format:"%Y-%m-%d"}{else}{$result->GetAge()|agestring}{/if} {if $searchtype == 'author'} {$result->GetAuthorName()|highlight:$search} {elseif $searchtype == 'committer'} {$result->GetCommitterName()|highlight:$search} {else} {$result->GetAuthorName()} {/if} GetTitle()) > 50}title="{$result->GetTitle()}"{/if}>{$result->GetTitle(50)} {if $searchtype == 'commit'} {foreach from=$result->SearchComment($search) item=line name=match}
{$line|highlight:$search:50} {/foreach} {/if}
{t}next{/t}
{include file='footer.tpl'}