diff --git a/src/com/silverwrist/venice/servlets/format/FindData.java b/src/com/silverwrist/venice/servlets/format/FindData.java index 3351503..ce46d84 100644 --- a/src/com/silverwrist/venice/servlets/format/FindData.java +++ b/src/com/silverwrist/venice/servlets/format/FindData.java @@ -390,4 +390,41 @@ public class FindData implements JSPRender, SearchMode } // end getCatJumpLink + public static String getCommunityHostName(CommunityContext comm) + { + try + { // get the host name for the specified community + UserProfile prof = comm.getHostProfile(); + return prof.getUserName(); + + } // end try + catch (DataException e) + { // just return NULL if an exception strikes + return null; + + } // end catch + + } // end getCommunityHostName + + public static int getCommunityMemberCount(CommunityContext comm) + { + try + { // get the member count for the specified community + return comm.getMemberCount(); + + } // end try + catch (DataException e) + { // just return -1 if an exception strikes + return -1; + + } // end catch + + } // end getCommunityMemberCount + + public static String getActivityString(CommunityContext comm, RenderData rdat) + { + return rdat.getActivityString(comm.getLastAccessDate()); + + } // end getActivityString + } // end class FindData diff --git a/web/format/find.jsp b/web/format/find.jsp index 9beebea..52e5a97 100644 --- a/web/format/find.jsp +++ b/web/format/find.jsp @@ -18,48 +18,8 @@ <%@ page import = "java.util.*" %> <%@ page import = "com.silverwrist.util.StringUtil" %> <%@ page import = "com.silverwrist.venice.core.*" %> -<%@ page import = "com.silverwrist.venice.except.*" %> <%@ page import = "com.silverwrist.venice.servlets.Variables" %> <%@ page import = "com.silverwrist.venice.servlets.format.*" %> -<%! -private static String getCommunityHostName(CommunityContext comm) -{ - try - { // get the host name for the specified community - UserProfile prof = comm.getHostProfile(); - return prof.getUserName(); - - } // end try - catch (DataException e) - { // just return NULL if an exception strikes - return null; - - } // end catch - -} // end getCommunityHostName - -private static int getCommunityMemberCount(CommunityContext comm) -{ - try - { // get the member count for the specified community - return comm.getMemberCount(); - - } // end try - catch (DataException e) - { // just return -1 if an exception strikes - return -1; - - } // end catch - -} // end getCommunityMemberCount - -private static String getActivityString(CommunityContext comm, RenderData rdat) -{ - return rdat.getActivityString(comm.getLastAccessDate()); - -} // end getActivityString - -%> <% FindData data = FindData.retrieve(request); Variables.failIfNull(data); @@ -106,7 +66,10 @@ private static String getActivityString(CommunityContext comm, RenderData rdat) <%= rdat.getStdFontTag(ColorSelectors.CONTENT_FOREGROUND,2) %> Display all categories whose name   - <% } else throw new InternalStateError("display parameter " + data.getDisplayOption() + " invalid"); %> + <% } else { %> + <%-- shouldn't get here --%> +

Display parameter invalid!

+ <% } // end if %>