<%@ Control Language="c#" AutoEventWireup="false" %>
<%@ Register TagPrefix="CS" Namespace="CommunityServer.Controls" Assembly="CommunityServer.Controls" %>
<%@ Register TagPrefix="CSD" Namespace="CommunityServer.Discussions.Controls" Assembly="CommunityServer.Discussions" %>
<%@ import Namespace="CommunityServer.Components" %>
<%@ import Namespace="CommunityServer.Controls" %>
<%@ import Namespace="CommunityServer" %>


<cs:StatusMessage runat="server" id="Status" />

<asp:PlaceHolder id="ResultsContainer" Runat="server">
	<div class="CommonSearchResultsArea">

	<div class="CommonSearchStatistics">
		<CS:CurrentPage id="ResultsTotal" runat="server" />
	</div>

	<asp:Repeater id="ResultsRepeater" runat="Server" EnableViewState="false">
		<HeaderTemplate>
			<ul class="CommonSearchResultList">
		</HeaderTemplate>
		<ItemTemplate>
			<li>
			<div class="CommonSearchResultArea">
				<h4 class="CommonSearchResultName"><a href="<%# DataBinder.Eval(Container.DataItem, "Url") %>"><%# DataBinder.Eval(Container.DataItem, "Title") %></a></h4>
				<div class="CommonSearchResult">
					<%# DataBinder.Eval(Container.DataItem, "BestMatch").ToString().Length > 0 ? DataBinder.Eval(Container.DataItem, "BestMatch") : Formatter.GetBodySummary(DataBinder.Eval(Container.DataItem, "Body").ToString(),350, new string[0], System.Drawing.Color.Black, System.Drawing.Color.Yellow) %>
				</div>
				<div class="CommonSearchResultDetails">
					<CS:ResourceLabel runat="server" ResourceName="SearchResults_PostTo" ID="Resourcelabel3"/>&nbsp;<asp:HyperLink Runat="server" ID = "SectionUrl" Text = '<%# DataBinder.Eval(Container.DataItem, "SectionName") %>' /> <a href ="<%# DataBinder.Eval(Container.DataItem, "ApplicationUrl") %>">(<%# DataBinder.Eval(Container.DataItem, "ApplicationType") %>)</a>&nbsp;<CS:ResourceLabel runat="server" ResourceName="SearchResults_By" ID="Resourcelabel4"/>&nbsp;<a href="<%# SiteUrls.Instance().UserProfile((string) DataBinder.Eval(Container.DataItem, "Username")) %>"><%# DataBinder.Eval(Container.DataItem, "Username") %></a>&nbsp;<CS:ResourceLabel runat="server" ResourceName="SearchResults_On" ID="Resourcelabel5"/>&nbsp;<%# DataBinder.Eval(Container.DataItem, "PostDate","{0:MMMM d, yyyy}") %>
					<%# (bool)DataBinder.Eval(Container.DataItem, "HasPostCategories") ? String.Concat("<br>", ResourceManager.GetString("TagListTitle"), String.Join(", ", (string[])DataBinder.Eval(Container.DataItem, "PostCategories"))) : ""%>
				</div>
			</div>
			</li>
		</ItemTemplate>
		<FooterTemplate>
			</ul>
		</FooterTemplate>
	</asp:Repeater>

	<div align="center" class="CommonPagingArea">
		<CS:Pager id="Pager" runat="server" />
	</div>
	
	</div>
</asp:PlaceHolder>

