<!--#include file="ContentOne/includes/userInclude.asp" -->
<!--#include file="ContentOne/includes/StringParser.asp" -->
<!--#include file="resume.asp" -->
<% 

'''''''''''''''''''''''' Function Descriptions and Usage '''''''''' ''''''''''''''''''''
''' DO NOT EDIT ANY FILES other than those in the root directory. ie. index.asp, page2.asp, global.asa and CSS style sheets.
''' All other code modifications require clearance through support@atlanticbt.com and another code version should be created for your request

'''''''''''''''''''''''''''' Functions '''''''''''''''''''''''''''''''''''''''''''''''''''

'' GetPageInfo(id,column)
'' this function returns information from the content table for the id and column specified
'' example usage: response.write GetPageInfo(1,"title")
'' columns: title, meta, content, category, sort_position, maingraphic, navdisplay

'' GetCategoryPages(category,pre,post,targeturl) -- this function returns the categories in basic format:
'' {pre}<a href="{targeturl}?id=x&category=y">category name</a>{post}
'' example usage: response.write GetCategoryPages(1,"<li>","</li>","/index.asp")

'' GetMainGraphic(id) -- this function returns the filename of the selected graphic for the page. 
'' If "random" is selected this will return a random graphic from the images folder
'' example usage: <img src="/maingraphics/GetMainGraphic(1)">

'' GetCategoryName(id) -- this function returns the name of the category
'' example usage: response.write GetCategoryName(id)

'' GetFeature(PageID, FeatureID, Pre, Post, displayTitle) -- this function returns the Page Feature wraped by pre and post

'''''''''''''''''''''''''' End Functions '''''''''''''''''''''''''''''''''''''''''''''''''

%>

<% id = request.querystring("id") %>
<% HomeID = GetHomePageID() %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title><%if id <> 0 then response.Write("MRINetwork The Sussex Group - " &GetPageInfo(id, "PageTitle")) else Response.Write("MRI Network The Sussex Group") end if%></title>
<link href="css/MRI_Template6.css" rel="stylesheet" type="text/css" />


</head>

<%
menu1 = 2
menu2 = 3
menu3 = 4


MainPaneID = GetNthPageFromCategory(1,1)
RightTopPaneID = GetNthPageFromCategory(1,2)
RightBottomPaneID = GetNthPageFromCategory(1,3)
%>

<body class="<% if id <> "" then %>inner<% else %>index<% end if %>">

<div id="date_strip">
	<div id="date">
		<%="Today's Date is "&MonthName(Month(date))&" "&Day(Date)&", "&year(date)%>
	</div>
</div>

<div id="container">

	<div id="header">
		<a href="index.asp"><!-- Link to Home Page--></a>
		<div id="searchbox">
		   <form action="index.asp<% if id <> "" then response.Write("?id=" & id & "&category=" & request.QueryString("category")) end if %>" name="search" method="get">
			<p>search this site:
			<% if id <> "" then %>
               <input type="hidden" name="id" id="id" value="<%=Request.QueryString("id")%>" />
               <input type="hidden" name="category" id="category" value="<%=Request.QueryString("category")%>" />
			<% end if %>
		       <input type="text" name="searchterm" id="searchterm" size="20" />
               <input type="hidden" name="submit" id="submit" value="submit" />
               <input type="submit" value="Search" />
		    </p>
			</form>
		</div>
	</div>

	<div id="leftcolumn">
		<div id="firstleft_box">
		<h2><span><%=GetCategoryName(menu1)%></span></h2>
		<ul>
			<%GetCategoryPages menu1,"<li>","</li>","index.asp"%>
		</ul>
		
		<% if id = "" then %>
			<h2>Our Services</h2>
			<ul>
				<li><a href="index.asp?id=<%=GetNthPageFromCategory(menu2,1)%>&category=<%=menu2%>"><%=GetCategoryName(menu2)%></a></li>
				<li><a href="index.asp?id=<%=GetNthPageFromCategory(menu3,1)%>&category=<%=menu3%>"><%=GetCategoryName(menu3)%></a></li>
			</ul>
		<div class="clean">
		<%
			GetFeature HomeID, 5, "", "", "", ""
		%>
		</div>
		<%
		else 
		%>
		
		<h2><span><%=GetCategoryName(menu2) %></span></h2>
		<ul>
			<% GetCategoryPages menu2,"<li>","</li>","index.asp" %>
		</ul>
		<h2><span><%=GetCategoryName(menu3) %></span></h2>
		<ul class="last">
			<% GetCategoryPages menu3,"<li>","</li>","index.asp" %>
		</ul>  
		<% end if %>
		
		</div>
	</div>

<div id="rightcolumn">

	<% if id <> "" then %>
	
		<% 
		GetFeature id, 5, "", "", "firstright_box", "" 
		preHTML = "<marquee direction =""up"" onMouseOut=this.scrollAmount=""2"" onMouseOver=this.scrollAmount=""1"" scrollamount =""2"">"
		postHTML = "</marquee>"		
		GetFeature id, 1, preHTML, postHTML, "firstright_box", "Testimonials"
		GetFeature id, 4, "", "", "firstright_box", "Poll" 
		%>
		
	<% else %>
		<div id="firstright_box">
			<h2 id="titleIntro"><%=GetPageInfo(RightTopPaneID, "PageTitle")%></h2>
			<%=GetPageInfo(RightTopPaneID, "Content")%>
		</div>
		<div id="firstright_box">
			<h2 id="titleIntro"><%=GetPageInfo(RightBottomPaneID, "PageTitle")%></h2>
			<%=GetPageInfo(RightBottomPaneID, "Content")%>
		</div>
	<% end if %>
</div>

<div id="center_box">

	<% if Request.QueryString("searchterm") <> "" and Request.QueryString("submit") = "submit" then %>
	<!--  Search Engine Results -->
			<h2>Search Results</h2>
			<% GetSearchResults(Request.QueryString("searchterm")) %>
	<% else %>
		<% if id <> "" then %>
			<h2><%=GetCategoryName( GetPageInfo(id, "ZoneID"))%></h2>
		<% else %>
			<h2><%=GetPageInfo(MainPaneID, "PageTitle")%></h2>
		<% end if %>
		
		
		<% if id <> "" then %>
		<div id="mainimage"><span><img src="/<%=Application("HeaderGraphicsFolder")%>/<%=GetMainGraphic(id)%>"></span></div>
		<% else %>
		<div id="mainimage"><span><img src="/<%=Application("HeaderGraphicsFolder")%>/HomeImages/<%=GetMainGraphic(HomeID)%>"></span></div>
		<% end if %>
		
		
		<% if id <> "" then %>
			<div id="content">
				<h2><%=GetPageInfo(id, "PageTitle")%></h2>
				<%if Request.ServerVariables("REQUEST_METHOD")= "POST" then 
					SendResume
				else %>
					<% formTest = GetPageInfo(id, "Content")
						if formTest = "InsertSubmitForm" then
							DisplayForm
						else
							response.Write(formTest)
						end if %>
				<% end if %>
			</div>
		<% else %>
			<div id="content">
				<%=GetPageInfo(MainPaneID, "Content")%>
			</div>
		<% end if %>
	<% end if %>
</div>

<div id="footerlinks">
	<ul>
		<li class="first"><a href="index.asp">Home</a></li>
		<% GenerateFooter %>
	</ul>
</div>
<div id="fine-print">
	<p>Copyright &copy; <%=Application("Year")%>&nbsp;<%=Application("CompanyTitle")%>. All Rights Reserved.</p>
	<p class="lite">Copyright &copy; <%=Application("Year")%>&nbsp;MRINetwork - All offices are independently owned and operated.</p>
	<div id="abt-link">
		<p><a href="http://www.atlanticbt.com/mrisolutions/" target="_blank" title="SnapSite&#8482; Web Template">This SnapSite&#8482;</a> <a href="http://www.atlanticbt.com/" target="_blank" title="Designed and Maintained by Atlantic BT">Designed and Maintained by Atlantic BT.</a><span></span></p>
		<p><a href="http://www.atlanticbt.com/mrisolutions/" target="_blank" title="Powered by ContentOne">Powered by ContentOne&#8482;</a></p>
	</div>
</div>
</div>

</body>
</html>
