<%-- The contents of this file are subject to the Mozilla Public License Version 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at . Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is the Venice Web Communities System. The Initial Developer of the Original Code is Eric J. Bowersox , for Silverwrist Design Studios. Portions created by Eric J. Bowersox are Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved. Contributor(s): --%> <%@ page import = "java.util.*" %> <%@ page import = "com.silverwrist.util.StringUtil" %> <%@ page import = "com.silverwrist.venice.core.*" %> <%@ page import = "com.silverwrist.venice.servlets.Variables" %> <%@ page import = "com.silverwrist.venice.servlets.format.*" %> <% FindPostData data = FindPostData.retrieve(request); Variables.failIfNull(data); RenderData rdat = RenderConfig.createRenderData(application,request,response); %> <% if (rdat.useHTMLComments()) { %><% } %> <% rdat.writeContentHeader(out,"Find Posts",data.getSubtitle()); %> <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %><%= data.getReturnLink(rdat) %>

">
<%= data.getExtraParameters() %> <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> Keywords:
" ALT="Search" WIDTH=80 HEIGHT=24 BORDER=0>

<% List results = data.getResults(); %> <% if (results!=null) { %> <% if (rdat.useHTMLComments()) { %><% } %> <% // Determine the number of results to display and whether to display a "next" button int dcount = results.size(); boolean go_next = false; if (dcount>data.getMaxResults()) { // there's a "next" dcount = data.getMaxResults(); go_next = true; } // end if %>


<%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,3) %> <%-- The initial search results --%> Search Results <% if (data.getFindCount()>0) { %> (Displaying <%= data.getOffset() + 1 %>-<%= data.getOffset() + dcount %> of <%= data.getFindCount() %>) <% } else { %>(None)<% } %> <% if (go_next || (data.getOffset()>0)) { %> <%-- The navigational form that allows us to page through the results --%> <% if (rdat.useHTMLComments()) { %><% } %>
">
<%= data.getExtraParameters() %> <% if (data.getOffset()>0) { %> " ALT="Previous" WIDTH=80 HEIGHT=24 BORDER=0> <% } else { %> " WIDTH=80 HEIGHT=24 BORDER=0> <% } // end if %>    <% if (go_next) { %> " ALT="Next" WIDTH=80 HEIGHT=24 BORDER=0> <% } else { %> " WIDTH=80 HEIGHT=24 BORDER=0> <% } // end if %>
<% } else { %> <% } %>

<%-- Display the results of the search --%> <% for (int i=0; i <% TopicMessageFound post = (TopicMessageFound)(results.get(i)); %> <% } // end for %>
<%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %>Post Link <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %>Author <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %>Post Date <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %>Lines  
<%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> "><%= post.getIdentifier() %> <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> "><%= post.getAuthor() %> <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> <%= rdat.formatDateForDisplay(post.getPostDate()) %> <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> <%= post.getLineCount() %> <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> <%= StringUtil.encodeHTML(post.getText()) %>

<% } // end if %>