modifications to ensure that Venice can operate without certain personal

information prompted for at registration time, if certain sites should elect
to omit that information
This commit is contained in:
Eric J. Bowersox 2004-07-10 22:54:15 +00:00
parent 5c0f841ab7
commit f0bf5e31ee
9 changed files with 431 additions and 348 deletions

View File

@ -8,9 +8,9 @@
//
// The Original Code is the Venice Web Communities System.
//
// The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
// The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
// for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
// Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
// Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
//
// Contributor(s):
@ -63,9 +63,16 @@ try
rinput.setRequestAttribute("address.lastline",buf.toString());
// get the full country name and save it off
ce = Packages.com.silverwrist.util.International.get().getCountryForCode(ci.country);
if (ce!=null)
rinput.setRequestAttribute("address.country",ce.name);
scountry = "";
if (!(ci.country.equals("XX")))
{ // use International to get the full country name
ce = Packages.com.silverwrist.util.International.get().getCountryForCode(ci.country);
if (ce!=null)
scountry = ce.name;
} // end if
rinput.setRequestAttribute("address.country",scountry);
// Save off the community logo tag.
html = vlib.queryHTMLRendering(rinput);

View File

@ -8,9 +8,9 @@
//
// The Original Code is the Venice Web Communities System.
//
// The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
// The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
// for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
// Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
// Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
//
// Contributor(s):
@ -34,30 +34,25 @@ try
buf = new java.lang.StringBuffer(prof.givenName);
if (!(vlib.emptyString(prof.namePrefix)))
{ // insert the prefix at the beginning of the string
buf.insert(0," ");
if (buf.length()>0)
buf.insert(0," ");
buf.insert(0,prof.namePrefix);
} // end if
tmp = String.fromCharCode(prof.middleInitial);
if (tmp!=" ")
{ // append the middle initial
buf.append(" ");
buf.append(tmp);
buf.append(".");
if (tmp!=" ") // append the middle initial
buf.append(" ").append(tmp).append(".");
} // end if
buf.append(" ");
buf.append(prof.familyName);
if (!(vlib.emptyString(prof.familyName)))
buf.append(" ").append(prof.familyName);
if (!(vlib.emptyString(prof.nameSuffix)))
{ // append the name suffix
buf.append(" ");
buf.append(prof.nameSuffix);
buf.append(" ").append(prof.nameSuffix);
} // end if
rinput.setRequestAttribute("fullname",buf.toString());
sfullname = buf.toString().trim();
if (vlib.emptyString(sfullname))
sfullname = username;
rinput.setRequestAttribute("fullname",sfullname);
// determine the last line of the address and save it off
if (vlib.emptyString(prof.locality))
@ -73,19 +68,22 @@ try
else
{ // tack together both locality and region
buf = new java.lang.StringBuffer(prof.locality);
buf.append(", ");
buf.append(prof.region);
buf.append(", ").append(prof.region);
} // end else
if (!(vlib.emptyString(prof.postalCode)))
{ // append the postal code
buf.append(" ");
buf.append(prof.postalCode);
buf.append(" ").append(prof.postalCode);
} // end if
rinput.setRequestAttribute("address.lastline",buf.toString());
rinput.setRequestAttribute("address.lastline",buf.toString().trim());
scountry = prof.fullCountry();
if (prof.country.equals("XX"))
scountry = "";
rinput.setRequestAttribute("country",scountry);
// Save off the user photo tag.
html = vlib.queryHTMLRendering(rinput);
@ -105,4 +103,4 @@ catch (e)
} // end catch
vlib.output(rc); // all done!
vlib.output(rc); // all done!

View File

@ -619,7 +619,14 @@ class UserContextImpl implements UserContext, ServiceProvider, PropertyProvider
if (my_email==null)
my_email = rc.getEmail();
if (full_name==null)
{ // compute the full name
full_name = rc.getGivenName() + " " + rc.getFamilyName();
full_name = full_name.trim();
if (StringUtil.isStringEmpty(full_name))
full_name = username;
} // end if
if (my_pseud==null)
my_pseud = full_name;
return rc;

View File

@ -86,7 +86,7 @@ public class BuildVCard
buf.append(family_name);
if (!StringUtil.isStringEmpty(suffix))
buf.append(' ').append(suffix);
String s = buf.toString();
String s = buf.toString().trim();
if (s.length()==0)
return null;
return s;

View File

@ -17,6 +17,7 @@
--%>
<%@ page import = "java.util.Iterator" %>
<%@ page import = "java.util.List" %>
<%@ page import = "com.silverwrist.util.*" %>
<%@ page import = "com.silverwrist.venice.core.*" %>
<%@ page import = "com.silverwrist.venice.ui.view.MembersView" %>
<%@ taglib uri="/tlds/util" prefix="util" %>
@ -36,43 +37,43 @@
</util:xlink>
]</util:font><p>
<% } // end if %>
<util:font color="content.fg" size="subhead"><B>Find members of community "<comm:name/>":</B></util:font><P>
<util:form action="comm/members.js.vs" type="servlet"><DIV CLASS="content">
<INPUT TYPE="HIDDEN" NAME="cc" VALUE="<comm:ID/>">
<INPUT TYPE="HIDDEN" NAME="sl" VALUE="0">
<INPUT TYPE="HIDDEN" NAME="ofs" VALUE="0">
<util:font color="content.fg" size="subhead"><b>Find members of community "<comm:name/>":</b></util:font><p />
<util:form action="comm/members.js.vs" type="servlet"><div class="content">
<input type="hidden" name="cc" value="<comm:ID/>" />
<input type="hidden" name="sl" value="0" />
<input type="hidden" name="ofs" value="0" />
<util:font color="content.fg" size="content">
Display all community members whose&nbsp;&nbsp;
<SELECT NAME="field" SIZE=1>
<OPTION VALUE="<%= SearchMode.FIELD_USER_NAME %>"
<% if (view.testField(SearchMode.FIELD_USER_NAME)) { %>SELECTED<% } %> >user name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_DESCRIPTION %>"
<% if (view.testField(SearchMode.FIELD_USER_DESCRIPTION)) { %>SELECTED<% } %> >description</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_GIVEN_NAME %>"
<% if (view.testField(SearchMode.FIELD_USER_GIVEN_NAME)) { %>SELECTED<% } %> >first name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_FAMILY_NAME %>"
<% if (view.testField(SearchMode.FIELD_USER_FAMILY_NAME)) { %>SELECTED<% } %> >last name</OPTION>
</SELECT><BR>
<select name="field" size="1">
<option value="<%= SearchMode.FIELD_USER_NAME %>"
<% if (view.testField(SearchMode.FIELD_USER_NAME)) { %>selected="selected"<% } %> >user name</option>
<option value="<%= SearchMode.FIELD_USER_DESCRIPTION %>"
<% if (view.testField(SearchMode.FIELD_USER_DESCRIPTION)) { %>selected="selected"<% } %> >description</option>
<option value="<%= SearchMode.FIELD_USER_GIVEN_NAME %>"
<% if (view.testField(SearchMode.FIELD_USER_GIVEN_NAME)) { %>selected="selected"<% } %> >first name</option>
<option value="<%= SearchMode.FIELD_USER_FAMILY_NAME %>"
<% if (view.testField(SearchMode.FIELD_USER_FAMILY_NAME)) { %>selected="selected"<% } %> >last name</option>
</select><br />
<SELECT NAME="mode" SIZE=1>
<OPTION VALUE="<%= SearchMode.SEARCH_PREFIX %>"
<% if (view.testMode(SearchMode.SEARCH_PREFIX)) { %>SELECTED<% } %> >starts with the string</OPTION>
<OPTION VALUE="<%= SearchMode.SEARCH_SUBSTRING %>"
<% if (view.testMode(SearchMode.SEARCH_SUBSTRING)) { %>SELECTED<% } %> >contains the string</OPTION>
<OPTION VALUE="<%= SearchMode.SEARCH_REGEXP %>"
<% if (view.testMode(SearchMode.SEARCH_REGEXP)) { %>SELECTED<% } %> >matches the regular
expression</OPTION>
</SELECT>
<select name="mode" size="1">
<option value="<%= SearchMode.SEARCH_PREFIX %>"
<% if (view.testMode(SearchMode.SEARCH_PREFIX)) { %>selected="selected"<% } %> >starts with the string</option>
<option value="<%= SearchMode.SEARCH_SUBSTRING %>"
<% if (view.testMode(SearchMode.SEARCH_SUBSTRING)) { %>selected="selected"<% } %> >contains the string</option>
<option value="<%= SearchMode.SEARCH_REGEXP %>"
<% if (view.testMode(SearchMode.SEARCH_REGEXP)) { %>selected="selected"<% } %> >matches the regular
expression</option>
</select>
<SPAN CLASS="cinput"><INPUT TYPE=TEXT CLASS="cinput" NAME="term" SIZE=32 MAXLENGTH=255
VALUE="<%= view.getTerm() %>"></SPAN><BR>
<span class="cinput"><input type="text" class="cinput" name="term" size="32" maxlength="255"
value="<%= view.getTerm() %>" /></span><br />
<util:button id="search" type="input"/>
</util:font>
</DIV></util:form>
</div></util:form>
<% List results = view.getResults(); %>
<% if (results!=null) { %>
<HR>
<hr />
<%
int dcount = results.size();
// Determine the number of results to display and whether to display a "next" button
@ -84,28 +85,28 @@
} // end if
%>
<TABLE WIDTH="100%" BORDER=0 ALIGN=CENTER><TR VALIGN=MIDDLE>
<TD WIDTH="50%" ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<table width="100%" border="0" align="center"><tr valign="middle">
<td width="50%" align="left" class="content"><util:font color="content.fg" size="content">
<%-- The community members/search results header --%>
<FONT SIZE=+1><B>
<font size="+1"><b>
<% if (view.getSimple()) { %>Community Members:<% } else { %>Search Results:<% } %>
</B></FONT>
</b></font>
(Displaying <%= view.getOffset() + 1 %>-<%= view.getOffset() + dcount %> of
<%= view.getFindCount() %>)
</util:font></TD>
</util:font></td>
<TD WIDTH="50%" ALIGN=RIGHT CLASS="content">
<td width="50%" align="right" class="content">
<% if (go_next || (view.getOffset()>0)) { %>
<%-- The navigational form that allows us to page through the results --%>
<util:comment>Navigational Form</util:comment>
<util:form action="comm/members.js.vs" type="servlet"><DIV CLASS="content">
<INPUT TYPE="HIDDEN" NAME="cc" VALUE="<comm:ID/>">
<INPUT TYPE="HIDDEN" NAME="sl" VALUE="<%= view.getSimple() ? 1 : 0 %>">
<INPUT TYPE=HIDDEN NAME="ofs" VALUE="<%= view.getOffset() %>">
<INPUT TYPE=HIDDEN NAME="field" VALUE="<%= view.getField() %>">
<INPUT TYPE=HIDDEN NAME="mode" VALUE="<%= view.getMode() %>">
<INPUT TYPE=HIDDEN NAME="term" VALUE="<%= view.getTerm() %>">
<INPUT TYPE=HIDDEN NAME="fcount" VALUE="<%= view.getFindCount() %>">
<util:form action="comm/members.js.vs" type="servlet"><div class="content">
<input type="hidden" name="cc" value="<comm:ID/>" />
<input type="hidden" name="sl" value="<%= view.getSimple() ? 1 : 0 %>" />
<input type="hidden" name="ofs" value="<%= view.getOffset() %>" />
<input type="hidden" name="field" value="<%= view.getField() %>" />
<input type="hidden" name="mode" value="<%= view.getMode() %>" />
<input type="hidden" name="term" value="<%= view.getTerm() %>" />
<input type="hidden" name="fcount" value="<%= view.getFindCount() %>" />
<% if (view.getOffset()>0) { %>
<util:button id="previous" type="input"/>
<% } else { %>
@ -117,33 +118,50 @@
<% } else { %>
<util:button id="_null_"/>
<% } // end if %>
</DIV></util:form>
</div></util:form>
<% } else { %>&nbsp;<% } %>
</TD>
</TR></TABLE><BR>
</td>
</tr></table><br />
<%-- Display the results of the search --%>
<TABLE BORDER=0 ALIGN=LEFT CELLPADDING=0 CELLSPACING=4>
<table border="0" align="left" cellpadding="0" cellspacing="4">
<% for (int i=0; i<dcount; i++) { %>
<TR VALIGN=TOP>
<TD ALIGN=CENTER WIDTH=14><util:stdbullet/></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<% UserFound uf = (UserFound)(results.get(i)); %>
<tr valign="top">
<td align="center" width="14"><util:stdbullet/></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<%
UserFound uf = (UserFound)(results.get(i));
String fullname = uf.getGivenName() + " " + uf.getFamilyName();
fullname = fullname.trim();
if (StringUtil.isStringEmpty(fullname))
fullname = uf.getName();
String whence = "";
if (!(StringUtil.isStringEmpty(uf.getLocality())))
{ // figure out the right locality
if (!(StringUtil.isStringEmpty(uf.getRegion())))
whence = uf.getLocality() + ", " + uf.getRegion();
else
whence = uf.getLocality();
} // end if
else if (!(StringUtil.isStringEmpty(uf.getRegion())))
whence = uf.getRegion();
%>
<util:xlink>
<util:href type="servlet">user/<%= uf.getName() %></util:href>
<util:text><%= uf.getName() %></util:text>
</util:xlink><BR>
<util:escape><%= uf.getGivenName() %> <%= uf.getFamilyName() %></util:escape>,
from <util:escape><%= uf.getLocality() %>, <%= uf.getRegion() %></util:escape>
<%= uf.getCountry() %>
</util:xlink><br />
<util:escape><%= fullname %></util:escape>, from <util:escape><%= whence %></util:escape>
<% if (!(uf.getCountry().equals("XX"))) { %><%= uf.getCountry() %><% } %>
<% if (view.isCommunityAdmin(uf)) { %>
&nbsp;<util:image src="tag_host.gif" fixup="true" alt="Host!" width="40" height="20"/>
<% } // end if %>
<% if (uf.getDescription()!=null) { %>
<BR><EM><util:escape><%= uf.getDescription() %></util:escape></EM>
<br /><i><util:escape><%= uf.getDescription() %></util:escape></i>
<% } // end if %>
</util:font></TD>
</TR>
</util:font></td>
</tr>
<% } // end for %>
</TABLE><BR CLEAR=LEFT>
</table><br clear="left" />
<% } // end if %>
<%-- EOF --%>

View File

@ -9,13 +9,14 @@
The Original Code is the Venice Web Communities System.
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
<%@ page import = "java.util.*" %>
<%@ page import = "com.silverwrist.util.*" %>
<%@ page import = "com.silverwrist.venice.core.*" %>
<%@ page import = "com.silverwrist.venice.ui.conf.CurrentConference" %>
<%@ page import = "com.silverwrist.venice.ui.menus.MenuComponent" %>
@ -38,72 +39,78 @@
</util:xlink></util:font><P>
<util:font color="content.fg" size="content">
<DIV ALIGN="LEFT"><B>Topic Subscription:</B></DIV>
<div align="left"><b>Topic Subscription:</b></div>
<topic:subscribed>
You are currently subscribed to this topic, and will receive all new posts to it via E-mail.<P>
<B><util:xlink>
You are currently subscribed to this topic, and will receive all new posts to it via E-mail.<p />
<b><util:xlink>
<util:href type="servlet">conf/subscribe_topic.js.vs?cc=<comm:ID/>&conf=<conf:ID/>&top=<topic:number/>&flag=0</util:href>
<util:text>Click Here to Stop Subscribing To This Topic</util:text>
</util:xlink></B>
</util:xlink></b>
</topic:subscribed>
<topic:not_subscribed>
You are not currently subscribed to this topic. When you subscribe to a topic, you will receive all new
posts to that topic via E-mail.<P>
<B><util:xlink>
posts to that topic via E-mail.<p />
<b><util:xlink>
<util:href type="servlet">conf/subscribe_topic.js.vs?cc=<comm:ID/>&conf=<conf:ID/>&top=<topic:number/>&flag=1</util:href>
<util:text>Click Here to Start Subscribing To This Topic</util:text>
</util:xlink></B>
</util:xlink></b>
</topic:not_subscribed>
<P>&nbsp;<P>
<p />&nbsp;<p />
<topic:can_send_invite>
<util:comment>Invitation Section</util:comment>
<util:header title="Send Invitation"/>
<util:font color="content.fg" size="content">
You may send an invitation via E-mail to outside individuals to join this community and
read this topic in the conference.<P>
<B><util:xlink>
read this topic in the conference.<p />
<b><util:xlink>
<util:href type="servlet">conf/invite_topic.js.vs?cc=<comm:ID/>&conf=<conf:ID/>&top=<topic:number/></util:href>
<util:text>Click Here to send an invitation</util:text>
</util:xlink></B>
</util:font><P>&nbsp;<P>
</util:xlink></b>
</util:font><p />&nbsp;<p />
</topic:can_send_invite>
<util:comment>Filtered Users Section</util:comment>
<util:header title="Filtered Users"/>
<% List bozos = (List)(view.getRequestAttribute("topic.bozos.list")); %>
<% if (bozos.size()>0) { %>
<TABLE BORDER=0 ALIGN=CENTER CELLPADDING=0 CELLSPACING=2>
<% Iterator it = bozos.iterator(); %>
<% while (it.hasNext()) { %>
<% UserProfile prof = (UserProfile)(it.next()); %>
<table border="0" align="center" cellpadding="0" cellspacing="2">
<% for (Iterator it=bozos.iterator(); it.hasNext(); ) { %>
<%
UserProfile prof = (UserProfile)(it.next());
String fullname = prof.getGivenName() + " " + prof.getFamilyName();
fullname = fullname.trim();
%>
<TR>
<TD ALIGN=CENTER WIDTH=16><util:xlink>
<td align="center" width="16"><util:xlink>
<util:href type="servlet">conf/remove_bozo.js.vs?cc=<comm:ID/>&conf=<conf:ID/>&top=<topic:number/>&u=<%= prof.getUID() %></util:href>
<util:text><util:image src="icn_x.gif" fixup="true" alt="Remove" width="16" height="16"/></util:text>
</util:xlink></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
</util:xlink></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
&lt;<util:xlink>
<util:href type="servlet">user/<%= prof.getUserName() %></util:href>
<util:text><%= prof.getUserName() %></util:text>
</util:xlink>&gt;
<EM><util:escape>(<%= prof.getGivenName() %> <%= prof.getFamilyName() %>)</util:escape></EM>
</util:font></TD>
</TR>
<% } // end while %>
</TABLE><P>
<% if (!(StringUtil.isStringEmpty(fullname))) { %>
<i><util:escape>(<%= fullname %>)</util:escape></i>
<% } // end if %>
</util:font></td>
</tr>
<% } // end for %>
</table><p />
<TABLE ALIGN=CENTER BORDER=0 CELLPADDING=2 CELLSPACING=0>
<TR VALIGN=TOP>
<TD ALIGN=CENTER WIDTH=16>
<table align="center" border="0" cellpadding="2" cellspacing="0">
<tr valign="top">
<td align="center" width="16">
<util:image src="icn_x.gif" fixup="true" alt="Remove" width="16" height="16"/>
</TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
</td>
<td alig="left" class="content"><util:font color="content.fg" size="content">
Click this symbol to cease filtering this user in this topic.
</util:font></TD>
</TR>
</TABLE>
</util:font></td>
</tr>
</table>
<% } else { %>
<DIV ALIGN="CENTER"><EM>No users currently filtered.</EM></DIV>
<div align="center"><i>No users currently filtered.</i></div>
<% } // end if %>
</util:font>
<%-- EOF --%>

View File

@ -9,14 +9,15 @@
The Original Code is the Venice Web Communities System.
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
<%@ page import = "java.util.Iterator" %>
<%@ page import = "java.util.List" %>
<%@ page import = "com.silverwrist.util.*" %>
<%@ page import = "com.silverwrist.venice.core.*" %>
<%@ page import = "com.silverwrist.venice.ui.view.FindView" %>
<%@ taglib uri="/tlds/util" prefix="util" %>
@ -77,86 +78,92 @@
<%-- Display the search form --%>
<util:comment>Find form</util:comment>
<util:form action="find.js.vs" type="servlet"><DIV CLASS="content">
<INPUT TYPE=HIDDEN NAME="disp" VALUE="<%= data.getDisplayMode() %>">
<INPUT TYPE=HIDDEN NAME="ofs" VALUE="0">
<util:form action="find.js.vs" type="servlet"><div class="content">
<input type="hidden" name="disp" value="<%= data.getDisplayMode() %>" />
<input type="hidden" name="ofs" VALUE="0" />
<% if (data.testDisplayMode(FindView.FD_POSTS)) { %>
<util:comment>Find Posts form</util:comment>
<util:font color="content.fg" size="content-heading"><B>Find Posts:</B></util:font>
<util:font color="content.fg" size="content-heading"><b>Find Posts:</b></util:font>
<util:font color="content.fg" size="content">
Keywords: <SPAN CLASS="cinput"><INPUT TYPE=TEXT CLASS="cinput" NAME="term" SIZE=64 MAXLENGTH=255
VALUE="<%= data.getTerm() %>"></SPAN>
</util:font><BR>
Keywords: <span class="cinput"><input type="text" class="cinput" name="term" size="64" maxlength="255"
value="<%= data.getTerm() %>" /></span>
</util:font><br />
<% } else { %>
<% if (data.testDisplayMode(FindView.FD_COMMUNITIES)) { %>
<util:comment>Find Communities form</util:comment>
<util:font color="content.fg" size="content-heading"><B>Find Communities:</B></util:font>
<util:font color="content.fg" size="content-heading"><b>Find Communities:</b></util:font>
<util:font color="content.fg" size="content">
Display all communities whose&nbsp;&nbsp;
<SELECT NAME="field" SIZE=1>
<OPTION VALUE="<%= SearchMode.FIELD_COMMUNITY_NAME %>"
<% if (data.testField(SearchMode.FIELD_COMMUNITY_NAME)) { %>SELECTED<% } %> >name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_COMMUNITY_SYNOPSIS %>"
<% if (data.testField(SearchMode.FIELD_COMMUNITY_SYNOPSIS)) { %>SELECTED<% } %> >synopsis</OPTION>
</SELECT><BR>
<select name="field" size="1">
<option value="<%= SearchMode.FIELD_COMMUNITY_NAME %>"
<% if (data.testField(SearchMode.FIELD_COMMUNITY_NAME)) { %>selected="selected"<% } %> >name</option>
<option value="<%= SearchMode.FIELD_COMMUNITY_SYNOPSIS %>"
<% if (data.testField(SearchMode.FIELD_COMMUNITY_SYNOPSIS)) { %>selected="selected"<% } %>
>synopsis</option>
</select><br />
</util:font>
<% } else if (data.testDisplayMode(FindView.FD_USERS)) { %>
<util:comment>Find Users form</util:comment>
<util:font color="content.fg" size="content-heading"><B>Find Users:</B></util:font>
<util:font color="content.fg" size="content-heading"><b>Find Users:</b></util:font>
<util:font color="content.fg" size="content">
Display all users whose&nbsp;&nbsp;
<SELECT NAME="field" SIZE=1>
<OPTION VALUE="<%= SearchMode.FIELD_USER_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_NAME)) { %>SELECTED<% } %> >user name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_DESCRIPTION %>"
<% if (data.testField(SearchMode.FIELD_USER_DESCRIPTION)) { %>SELECTED<% } %> >description</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_GIVEN_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_GIVEN_NAME)) { %>SELECTED<% } %> >first name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_FAMILY_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_FAMILY_NAME)) { %>SELECTED<% } %> >last name</OPTION>
</SELECT><BR>
<select name="field" size="1">
<option value="<%= SearchMode.FIELD_USER_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_NAME)) { %>selected="selected"<% } %> >user name</option>
<option value="<%= SearchMode.FIELD_USER_DESCRIPTION %>"
<% if (data.testField(SearchMode.FIELD_USER_DESCRIPTION)) { %>selected="selected"<% } %>
>description</option>
<option value="<%= SearchMode.FIELD_USER_GIVEN_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_GIVEN_NAME)) { %>selected="selected"<% } %> >first
name</option>
<option value="<%= SearchMode.FIELD_USER_FAMILY_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_FAMILY_NAME)) { %>selected="selected"<% } %> >last
name</option>
</select><br />
</util:font>
<% } else if (data.testDisplayMode(FindView.FD_CATEGORIES)) { %>
<global:categories_enabled>
<util:comment>Find Categories form</util:comment>
<util:font color="content.fg" size="content-heading"><B>Find Categories:</B></util:font>
<util:font color="content.fg" size="content-heading"><b>Find Categories:</b></util:font>
<util:font color="content.fg" size="content">
Display all categories whose name&nbsp;&nbsp;
</util:font>
</global:categories_enabled>
<global:categories_disabled>
<%-- shouldn't get here --%>
<H1><FONT COLOR="red">Display parameter invalid!</FONT></H1>
<h1><font color="red">Display parameter invalid!</font></h1>
</global:categories_disabled>
<% } else { %>
<%-- shouldn't get here --%>
<H1><FONT COLOR="red">Display parameter invalid!</FONT></H1>
<h1><font color="red">Display parameter invalid!</font></h1>
<% } // end if %>
<util:font color="content.fg" size="content">
<SELECT NAME="mode" SIZE=1>
<OPTION VALUE="<%= SearchMode.SEARCH_PREFIX %>"
<% if (data.testMode(SearchMode.SEARCH_PREFIX)) { %>SELECTED<% } %> >starts with the string</OPTION>
<OPTION VALUE="<%= SearchMode.SEARCH_SUBSTRING %>"
<% if (data.testMode(SearchMode.SEARCH_SUBSTRING)) { %>SELECTED<% } %> >contains the string</OPTION>
<OPTION VALUE="<%= SearchMode.SEARCH_REGEXP %>"
<% if (data.testMode(SearchMode.SEARCH_REGEXP)) { %>SELECTED<% } %> >matches the regular
expression</OPTION>
</SELECT>
<% if (data.testDisplayMode(FindView.FD_CATEGORIES)) { %><BR><% } else { %>&nbsp;&nbsp;<% } %>
<SPAN CLASS="cinput"><INPUT TYPE=TEXT CLASS="cinput" NAME="term" SIZE=32 MAXLENGTH=255
VALUE="<%= data.getTerm() %>"></SPAN><BR>
<select name="mode" size="1">
<option value="<%= SearchMode.SEARCH_PREFIX %>"
<% if (data.testMode(SearchMode.SEARCH_PREFIX)) { %>selected="selected"<% } %> >starts with the
string</option>
<option value="<%= SearchMode.SEARCH_SUBSTRING %>"
<% if (data.testMode(SearchMode.SEARCH_SUBSTRING)) { %>selected="selected"<% } %> >contains the
string</option>
<option value="<%= SearchMode.SEARCH_REGEXP %>"
<% if (data.testMode(SearchMode.SEARCH_REGEXP)) { %>selected="selected"<% } %> >matches the regular
expression</option>
</select>
<% if (data.testDisplayMode(FindView.FD_CATEGORIES)) { %><br /><% } else { %>&nbsp;&nbsp;<% } %>
<span class="cinput"><input type="text" class="cinput" name="term" size="32" maxlength="255"
value="<%= data.getTerm() %>"></span><br />
</util:font>
<% } // end if %>
<util:button id="search" type="input"/>
</DIV></util:form>
</div></util:form>
<%-- Display the current category --%>
<global:categories_enabled>
<% cat = data.getCategory(); %>
<% if (cat!=null) { %>
<util:comment>Display Category Name</util:comment>
<HR><util:font color="content.fg" size="subhead">
<B>Category:
<hr /><util:font color="content.fg" size="subhead">
<b>Category:
<% if (cat.getCategoryID()<0) { %>
Top
<% } else { %>
@ -178,21 +185,20 @@
<% } // end if %>
<% } // end for %>
<% } // end if (displaying the subcategory tree) %>
</B><P>
</b><P>
<%-- Display the subcategory list --%>
<% List subcats = data.getSubCategories(); %>
<% if ((subcats!=null) && (subcats.size()>0)) { %>
<util:comment>Display Subcategory List</util:comment>
<B>Subcategories:</B><BR>
<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=2>
<% Iterator it = subcats.iterator(); %>
<% while (it.hasNext()) { %>
<TR VALIGN=TOP>
<TD ALIGN=CENTER WIDTH=14><util:stdbullet/></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<% CategoryDescriptor c = (CategoryDescriptor)(it.next()); %>
<B><util:xlink>
<b>Subcategories:</b><br />
<table border="0" cellpadding="0" cellspacing="2">
<% for (Iterator it = subcats.iterator(); it.hasNext(); ) { %>
<% CategoryDescriptor c = (CategoryDescriptor)(it.next()); %>
<tr valign="top">
<td align="center" width="14"><util:stdbullet/></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<b><util:xlink>
<util:href type="servlet">
find.js.vs?disp=<%= FindView.FD_COMMUNITIES %>&cat=<%= c.getLinkedCategoryID() %>
</util:href>
@ -200,11 +206,11 @@
<util:escape><%= c.getTitleAtLevel(c.getNumLevels()-1) %></util:escape>
</util:text>
</util:xlink>
<% if (c.isSymbolicLink()) { %><EM>@</EM><% } %>
</util:font></TD>
</TR>
<% } // end while %>
</TABLE>
<% if (c.isSymbolicLink()) { %><i>@</i><% } %>
</util:font></td>
</tr>
<% } // end for %>
</table>
<% } // end if (displaying subcategory list) %>
</util:font>
<% } // end if (category specified) %>
@ -225,29 +231,29 @@
} // end if
%>
<HR>
<TABLE WIDTH="100%" BORDER=0 ALIGN=CENTER><TR VALIGN=MIDDLE>
<TD WIDTH="50%" ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<hr />
<table width="100%" border="0" align="center"><tr valign="middle">
<td width="50%" align="left" class="content"><util:font color="content.fg" size="content">
<%-- The initial search results --%>
<B><% if (cat!=null) { %>Communities in Category<% } else { %>Search Results<% } %></B>
<b><% if (cat!=null) { %>Communities in Category<% } else { %>Search Results<% } %></b>
<% if (data.getFindCount()>0) { %>
(Displaying <%= data.getOffset() + 1 %>-<%= data.getOffset() + dcount %> of
<%= data.getFindCount() %>)
<% } else { %>(None)<% } %>
</util:font></TD>
</util:font></td>
<TD WIDTH="50%" ALIGN=RIGHT CLASS="content">
<td width="50%" align="right" class="content">
<% if (go_next || (data.getOffset()>0)) { %>
<%-- The navigational form that allows us to page through the results --%>
<util:comment>Navigational form</util:comment>
<util:form action="find.js.vs" type="servlet"><DIV CLASS="content">
<INPUT TYPE=HIDDEN NAME="disp" VALUE="<%= data.getDisplayMode() %>">
<% if (cat!=null) { %><INPUT TYPE=HIDDEN NAME="cat" VALUE="<%= cat.getCategoryID() %>"><% } %>
<INPUT TYPE=HIDDEN NAME="ofs" VALUE="<%= data.getOffset() %>">
<INPUT TYPE=HIDDEN NAME="field" VALUE="<%= data.getField() %>">
<INPUT TYPE=HIDDEN NAME="mode" VALUE="<%= data.getMode() %>">
<INPUT TYPE=HIDDEN NAME="term" VALUE="<%= data.getTerm() %>">
<INPUT TYPE=HIDDEN NAME="fcount" VALUE="<%= data.getFindCount() %>">
<util:form action="find.js.vs" type="servlet"><div class="content">
<input type="hidden" name="disp" value="<%= data.getDisplayMode() %>" />
<% if (cat!=null) { %><input type="hidden" name="cat" value="<%= cat.getCategoryID() %>" /><% } %>
<input type="hidden" name="ofs" value="<%= data.getOffset() %>" />
<input type="hidden" name="field" value="<%= data.getField() %>" />
<input type="hidden" name="mode" value="<%= data.getMode() %>" />
<input type="hidden" name="term" value="<%= data.getTerm() %>" />
<input type="hidden" name="fcount" value="<%= data.getFindCount() %>" />
<% if (data.getOffset()>0) { %>
<util:button id="previous" type="input"/>
<% } else { %>
@ -259,58 +265,58 @@
<% } else { %>
<util:button id="_null_"/>
<% } // end if %>
</DIV></util:form>
</div></util:form>
<% } else { %>&nbsp;<% } %>
</TD>
</TR></TABLE><BR>
</td>
</tr></table><br />
<%-- Display the results of the search --%>
<TABLE BORDER=0 ALIGN=LEFT CELLPADDING=0 CELLSPACING=4>
<table border="0" align="left" cellpadding="0" cellspacing="4">
<% if (data.testDisplayMode(FindView.FD_POSTS) && (dcount>0)) { %>
<TR VALIGN=TOP>
<TH ALIGN=LEFT CLASS="CONTENT">
<util:font color="content.fg" size="content"><B><U>Post Link</U></B></util:font>
</TH>
<TH ALIGN=LEFT CLASS="CONTENT">
<util:font color="content.fg" size="content"><B><U>Author</U></B></util:font>
</TH>
<TH ALIGN=LEFT CLASS="CONTENT">
<util:font color="content.fg" size="content"><B><U>Post Date</U></B></util:font>
</TH>
<TH ALIGN=LEFT CLASS="CONTENT">
<util:font color="content.fg" size="content"><B><U>Lines</U></B></util:font>
</TH>
<TH ALIGN=LEFT CLASS="CONTENT">&nbsp;</TH>
</TR>
<tr valign="top">
<th align="left" class="content">
<util:font color="content.fg" size="content"><b><u>Post Link</u></b></util:font>
</th>
<th align="left" class="content">
<util:font color="content.fg" size="content"><b><u>Author</u></b></util:font>
</th>
<th align="left" class="content">
<util:font color="content.fg" size="content"><b><u>Post Date</u></b></util:font>
</th>
<th align="left" class="content">
<util:font color="content.fg" size="content"><b><u>Lines</u></b></util:font>
</th>
<th align="left" class="content">&nbsp;</th>
</tr>
<% } // end if %>
<% for (int i=0; i<dcount; i++) { %>
<TR VALIGN=TOP>
<tr valign="top">
<% if (data.testDisplayMode(FindView.FD_POSTS)) { %>
<% TopicMessageFound post = (TopicMessageFound)(results.get(i)); %>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<td align="left" class="content"><util:font color="content.fg" size="content">
<util:xlink>
<util:href type="servlet">go/<%= post.getIdentifier() %></util:href>
<util:text><%= post.getIdentifier() %></util:text>
</util:xlink>
</util:font></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
</util:font></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<util:xlink>
<util:href type="servlet">user/<%= post.getAuthor() %></util:href>
<util:text><%= post.getAuthor() %></util:text>
</util:xlink>
</util:font></TD>
<TD ALIGN=LEFT CLASS="content" NOWRAP><util:font color="content.fg" size="content">
</util:font></td>
<td align="left" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<%= data.formatDate(post.getPostDate()) %>
</util:font></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
</util:font></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<%= post.getLineCount() %>
</util:font></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
</util:font></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<util:escape><%= post.getText() %></util:escape>
</util:font></TD>
</util:font></td>
<% } else { %>
<TD ALIGN=CENTER WIDTH=14><util:stdbullet/></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<td align="center" width="14"><util:stdbullet/></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<% Object item = results.get(i); %>
<% if (data.testDisplayMode(FindView.FD_COMMUNITIES)) { %>
<%
@ -319,9 +325,9 @@
int members = FindView.getCommunityMemberCount(comm);
%>
<util:xlink>
<util:href type="servlet">sig/<%= comm.getAlias() %></util:href>
<util:href type="servlet">comm/<%= comm.getAlias() %></util:href>
<util:text><util:escape><%= comm.getName() %></util:escape></util:text>
</util:xlink><BR>
</util:xlink><br />
<% if (host_name!=null) { %>
Host:
<util:xlink>
@ -333,21 +339,37 @@
<% if (host_name!=null) { %> - <% } %>
<%= members %> members
<% } // end if (got member count) %>
<% if ((host_name!=null) || (members>=0)) { %><BR><% } %>
Latest activity: <%= data.getActivityString(comm.getLastAccessDate()) %><BR>
<EM><util:escape><%= comm.getSynopsis() %></util:escape></EM>
<% if ((host_name!=null) || (members>=0)) { %><br /><% } %>
Latest activity: <%= data.getActivityString(comm.getLastAccessDate()) %><br />
<i><util:escape><%= comm.getSynopsis() %></util:escape><i>
<% } else if (data.testDisplayMode(FindView.FD_USERS)) { %>
<% UserFound uf = (UserFound)item; %>
<%
UserFound uf = (UserFound)item;
String fullname = uf.getGivenName() + " " + uf.getFamilyName();
fullname = fullname.trim();
if (StringUtil.isStringEmpty(fullname))
fullname = uf.getName();
String whence = "";
if (!(StringUtil.isStringEmpty(uf.getLocality())))
{ // combine locations
if (!(StringUtil.isStringEmpty(uf.getRegion())))
whence = uf.getLocality() + ", " + uf.getRegion();
else
whence = uf.getLocality();
} // end if
else if (!(StringUtil.isStringEmpty(uf.getRegion())))
whence = uf.getRegion();
%>
<util:xlink>
<util:href type="servlet">user/<%= uf.getName() %></util:href>
<util:text><%= uf.getName() %></util:text>
</util:xlink><BR>
<util:escape><%= uf.getGivenName() %></util:escape>
<util:escape><%= uf.getFamilyName() %></util:escape>,
from <util:escape><%= uf.getLocality() %></util:escape>,
<util:escape><%= uf.getRegion() %></util:escape> <%= uf.getCountry() %>
</util:xlink><br />
<util:escape><%= fullname %></util:escape>,
from <util:escape><%= whence %></util:escape>
<% if (!(uf.getCountry().equals("XX"))) { %><%= uf.getCountry() %><% } %>
<% if (uf.getDescription()!=null) { %>
<BR><EM><util:escape><%= uf.getDescription() %></util:escape></EM>
<br /><i><util:escape><%= uf.getDescription() %></util:escape></i>
<% } // end if %>
<% } else if (data.testDisplayMode(FindView.FD_CATEGORIES)) { %>
<global:categories_enabled>
@ -360,9 +382,10 @@
</util:xlink>
</global:categories_enabled>
<% } // end if %>
</util:font></TD>
</util:font></td>
<% } // end if %>
</TR>
</tr>
<% } // end for %>
</TABLE><BR CLEAR=LEFT>
</table><br clear="left" />
<% } // end if (results found) %>
<%-- EOF --%>

View File

@ -9,9 +9,9 @@
The Original Code is the Venice Web Communities System.
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
@ -30,36 +30,36 @@ System Administration Menu</util:link></util:font><P>
<%-- Display the search form --%>
<util:comment>User Search Form</util:comment>
<util:form action="sysadmin/find_user.js.vs" type="servlet"><DIV CLASS="content">
<INPUT TYPE=HIDDEN NAME="ofs" VALUE="0">
<util:font color="content.fg" size="content-heading"><B>Find Users:</B></util:font><BR>
<util:form action="sysadmin/find_user.js.vs" type="servlet"><div class="content">
<input type="hidden" name="ofs" value="0" />
<util:font color="content.fg" size="content-heading"><b>Find Users:</b></util:font><br />
<util:font color="content.fg" size="content">
Display all users whose&nbsp;&nbsp;
<SELECT NAME="field" SIZE=1>
<OPTION VALUE="<%= SearchMode.FIELD_USER_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_NAME)) { %>SELECTED<% } %> >user name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_DESCRIPTION %>"
<% if (data.testField(SearchMode.FIELD_USER_DESCRIPTION)) { %>SELECTED<% } %> >description</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_GIVEN_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_GIVEN_NAME)) { %>SELECTED<% } %> >first name</OPTION>
<OPTION VALUE="<%= SearchMode.FIELD_USER_FAMILY_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_FAMILY_NAME)) { %>SELECTED<% } %> >last name</OPTION>
</SELECT><BR>
<SELECT NAME="mode" SIZE=1>
<OPTION VALUE="<%= SearchMode.SEARCH_PREFIX %>"
<% if (data.testMode(SearchMode.SEARCH_PREFIX)) { %>SELECTED<% } %> >starts with the string</OPTION>
<OPTION VALUE="<%= SearchMode.SEARCH_SUBSTRING %>"
<% if (data.testMode(SearchMode.SEARCH_SUBSTRING)) { %>SELECTED<% } %> >contains the string</OPTION>
<OPTION VALUE="<%= SearchMode.SEARCH_REGEXP %>"
<% if (data.testMode(SearchMode.SEARCH_REGEXP)) { %>SELECTED<% } %> >matches the regular
expression</OPTION>
</SELECT>
<select name="field" size="1">
<option value="<%= SearchMode.FIELD_USER_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_NAME)) { %>selected="selected"<% } %> >user name</option>
<option value="<%= SearchMode.FIELD_USER_DESCRIPTION %>"
<% if (data.testField(SearchMode.FIELD_USER_DESCRIPTION)) { %>selected="selected"<% } %> >description</option>
<option value="<%= SearchMode.FIELD_USER_GIVEN_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_GIVEN_NAME)) { %>selected="selected"<% } %> >first name</option>
<option value="<%= SearchMode.FIELD_USER_FAMILY_NAME %>"
<% if (data.testField(SearchMode.FIELD_USER_FAMILY_NAME)) { %>selected="selected"<% } %> >last name</option>
</select><br />
<select name="mode" size="1">
<option value="<%= SearchMode.SEARCH_PREFIX %>"
<% if (data.testMode(SearchMode.SEARCH_PREFIX)) { %>selected="selected"<% } %> >starts with the string</option>
<option value="<%= SearchMode.SEARCH_SUBSTRING %>"
<% if (data.testMode(SearchMode.SEARCH_SUBSTRING)) { %>selected="selected"<% } %> >contains the string</option>
<option value="<%= SearchMode.SEARCH_REGEXP %>"
<% if (data.testMode(SearchMode.SEARCH_REGEXP)) { %>selected="selected"<% } %> >matches the regular
expression</option>
</select>
&nbsp;&nbsp;
<SPAN CLASS="cinput"><INPUT TYPE=TEXT CLASS="cinput" NAME="term" SIZE=32 MAXLENGTH=255
VALUE="<%= data.getTerm() %>"></SPAN><BR>
<util:button id="search" type="input"/><BR>
<span class="cinput"><input type="text" class="cinput" name="term" size="32" maxlength="255"
value="<%= data.getTerm() %>" /></span><br />
<util:button id="search" type="input"/><br />
</util:font>
</DIV></util:form>
</div></util:form>
<% List results = data.getResults(); %>
<% if (results!=null) { %>
@ -75,26 +75,26 @@ System Administration Menu</util:link></util:font><P>
} // end if
%>
<HR>
<TABLE WIDTH="100%" BORDER=0 ALIGN=CENTER><TR VALIGN=MIDDLE>
<TD WIDTH="50%" ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="subhead">
<hr />
<table width="100%" border="0" align="center"><tr valign="middle">
<td width="50%" align="left" class="content"><util:font color="content.fg" size="subhead">
<%-- The initial search results --%>
<B>Search Results</B>
<b>Search Results</b>
<% if (data.getFindCount()>0) { %>
(Displaying <%= data.getOffset() + 1 %>-<%= data.getOffset() + dcount %> of
<%= data.getFindCount() %>)
<% } else { %>(None)<% } %>
</util:font></TD>
<TD WIDTH="50%" ALIGN=RIGHT CLASS="content">
</util:font></td>
<td width="50%" align="right" class="content">
<% if (go_next || (data.getOffset()>0)) { %>
<%-- The navigational form that allows us to page through the results --%>
<util:comment>Navigational Form</util:comment>
<util:form action="sysadmin/find_user.js.vs" type="servlet"><DIV CLASS="content">
<INPUT TYPE=HIDDEN NAME="ofs" VALUE="<%= data.getOffset() %>">
<INPUT TYPE=HIDDEN NAME="field" VALUE="<%= data.getField() %>">
<INPUT TYPE=HIDDEN NAME="mode" VALUE="<%= data.getMode() %>">
<INPUT TYPE=HIDDEN NAME="term" VALUE="<%= data.getTerm() %>">
<INPUT TYPE=HIDDEN NAME="fcount" VALUE="<%= data.getFindCount() %>">
<util:form action="sysadmin/find_user.js.vs" type="servlet"><div class="content">
<input type="hidden" name="ofs" value="<%= data.getOffset() %>" />
<input type="hidden" name="field" value="<%= data.getField() %>" />
<input type="hidden" name="mode" value="<%= data.getMode() %>" />
<input type="hidden" name="term" value="<%= data.getTerm() %>" />
<input type="hidden" name="fcount" value="<%= data.getFindCount() %>" />
<% if (data.getOffset()>0) { %>
<util:button id="previous" type="input"/>
<% } else { %>
@ -106,33 +106,52 @@ System Administration Menu</util:link></util:font><P>
<% } else { %>
<util:button id="_null_"/>
<% } // end if %>
</DIV></util:form>
</div></util:form>
<% } else { %>&nbsp;<% } %>
</TD>
</TR></TABLE><BR>
</td>
</tr></table><br />
<%-- Display the results of the search --%>
<TABLE BORDER=0 ALIGN=LEFT CELLPADDING=0 CELLSPACING=4>
<table border="0" align="left" cellpadding="0" cellspacing="4">
<% for (int i=0; i<dcount; i++) { %>
<TR VALIGN=TOP>
<TD ALIGN=CENTER WIDTH=14><util:stdbullet/></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<% UserFound uf = (UserFound)(results.get(i)); %>
<tr valign="top">
<td align="center" width="14"><util:stdbullet/></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<%
UserFound uf = (UserFound)(results.get(i));
String fullname = uf.getGivenName() + " " + uf.getFamilyName();
fullname = fullname.trim();
if (StringUtil.isStringEmpty(fullname))
fullname = uf.getName();
String whence = "";
if (!(StringUtil.isStringEmpty(uf.getLocality())))
{ // combine locations
if (!(StringUtil.isStringEmpty(uf.getRegion())))
whence = uf.getLocality() + ", " + uf.getRegion();
else
whence = uf.getLocality();
} // end if
else if (!(StringUtil.isStringEmpty(uf.getRegion())))
whence = uf.getRegion();
%>
<util:xlink>
<util:href type="servlet">user/<%= uf.getName() %></util:href>
<util:text><%= uf.getName() %></util:text>
</util:xlink><BR>
<util:escape><%= uf.getGivenName() %> <%= uf.getFamilyName() %></util:escape>,
from <util:escape><%= uf.getLocality() %>, <%= uf.getRegion() %></util:escape> <%= uf.getCountry() %>
</util:xlink><br />
<util:escape><%= fullname %></util:escape>,
from <util:escape><%= whence %></util:escape>
<% if (!(uf.getCountry().equals("XX"))) { %><%= uf.getCountry() %><% } %>
<% if (!StringUtil.isStringEmpty(uf.getDescription())) { %>
<BR><EM><util:escape><%= uf.getDescription() %></util:escape></EM>
<br /><i><util:escape><%= uf.getDescription() %></util:escape></i>
<% } // end if %>
<BR><util:xlink>
<br /><util:xlink>
<util:href type="servlet">sysadmin/modify_user.js.vs?uid=<%= uf.getUID() %></util:href>
<util:text>[Modify User]</util:text>
</util:xlink>
</util:font></TD>
</TR>
</util:font></td>
</tr>
<% } // end for %>
</TABLE><BR CLEAR=LEFT>
</table><br clear="left" />
<% } // end if (results found) %>
<%-- EOF --%>

View File

@ -9,9 +9,9 @@
The Original Code is the Venice Web Communities System.
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
@ -26,72 +26,76 @@
%>
<util:comment>Profile for UID #<%= prof.getUID() %></util:comment>
<util:header title="User Profile:" subtitle="<%= prof.getUserName() %>"/>
<TABLE BORDER=0 CELLPADDING=6 CELLSPACING=0><TR VALIGN=TOP>
<TD ALIGN=LEFT CLASS="c2"><util:font color="content.fg" size="profile-dates">
<%= data.getRequestAttribute("user.photo") %><BR CLEAR=LEFT><P>
<table border="0" cellpadding="6" cellspacing="0"><tr valign="top">
<td align="left" class="c2"><util:font color="content.fg" size="profile-dates">
<%= data.getRequestAttribute("user.photo") %><br clear="left" /><p />
<% java.util.Date tmpd = prof.getCreateDate(); %>
<% if (tmpd!=null) { %>
Account created:<BR><util:escape><%= data.formatDate(tmpd) %></util:escape><BR>
Account created:<br /><util:escape><%= data.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<% tmpd = prof.getLastLoginDate(); %>
<% if (tmpd!=null) { %>
Last login:<BR><util:escape><%= data.formatDate(tmpd) %></util:escape><BR>
Last login:<br /><util:escape><%= data.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<% tmpd = prof.getLastUpdate(); %>
<% if (tmpd!=null) { %>
Profile last updated:<BR><util:escape><%= data.formatDate(tmpd) %></util:escape><BR>
Profile last updated:<br /><util:escape><%= data.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
</util:font></TD>
</util:font></td>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<B><util:escape><%= data.getRequestAttribute("fullname").toString() %></util:escape></B><BR>
<% tmp = prof.getEmail(); %>
<td align="left" class="content"><util:font color="content.fg" size="content">
<util:comment>fullname</util:comment><% tmp = data.getRequestAttribute("fullname").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>
E-mail: <A HREF="mailto:<%= tmp %>"><util:escape><%= tmp %></util:escape></A><BR>
<b><util:escape><%= tmp %></util:escape></b><br />
<% } // end if %>
<% tmp = prof.getURL(); %>
<util:comment>e-mail</util:comment><% tmp = prof.getEmail(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>
URL: <A HREF="<%= tmp %>" TARGET="Wander"><util:escape><%= tmp %></util:escape></A><BR>
<% } // end if %><BR>
<% tmp = prof.getCompany(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = prof.getAddressLine1(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = prof.getAddressLine2(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = data.getRequestAttribute("address.lastline").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = prof.getFullCountry(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = prof.getPhone(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>Phone: <util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = prof.getFax(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>Fax: <util:escape><%= tmp %></util:escape><BR><% } %>
<% tmp = prof.getMobile(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>Mobile: <util:escape><%= tmp %></util:escape><BR><% } %>
</util:font></TD>
</TR></TABLE><BR>
E-mail: <a href="mailto:<%= tmp %>"><util:escape><%= tmp %></util:escape></a><br />
<% } // end if %>
<util:comment>url</util:comment><% tmp = prof.getURL(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>
URL: <a href="<%= tmp %>" target="Wander"><util:escape><%= tmp %></util:escape></a><br />
<% } // end if %><br />
<util:comment>company</util:comment><% tmp = prof.getCompany(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>address 1</util:comment><% tmp = prof.getAddressLine1(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>address 2</util:comment><% tmp = prof.getAddressLine2(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>address lastline</util:comment><% tmp = data.getRequestAttribute("address.lastline").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>country</util:comment><% tmp = data.getRequestAttribute("country").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>phone</util:comment><% tmp = prof.getPhone(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>Phone: <util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>fax</util:comment><% tmp = prof.getFax(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>Fax: <util:escape><%= tmp %></util:escape><br /><% } %>
<util:comment>mobile</util:comment><% tmp = prof.getMobile(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>Mobile: <util:escape><%= tmp %></util:escape><br /><% } %>
</util:font></td>
</tr></table><br />
<% tmp = prof.getDescription(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %>
<util:font color="content.fg" size="content"><EM><util:escape><%= tmp %></util:escape></EM></util:font><BR>
<util:font color="content.fg" size="content"><i><util:escape><%= tmp %></util:escape></i></util:font><br />
<% } // end if %>
<% if (prof.canSendQuickEmail()) { %>
<HR><util:font color="content.fg" size="content"><B>Send Quick E-Mail To
<%= prof.getUserName() %>:</B></util:font><BR>
<hr /><util:font color="content.fg" size="content"><b>Send Quick E-Mail To
<%= prof.getUserName() %>:</b></util:font><br />
<util:form action="quick_email.js.vs" type="servlet">
<INPUT TYPE="HIDDEN" NAME="to_uid" VALUE="<%= prof.getUID() %>">
<TABLE BORDER=0 CELLPADDING=0>
<TR VALIGN=MIDDLE><TD ALIGN=LEFT CLASS="content">
<input type="hidden" name="to_uid" value="<%= prof.getUID() %>" />
<table border="0" cellpadding="0">
<tr valign="middle"><td align="left" class="content">
<util:font color="content.fg" size="content">Subject: </util:font>
<SPAN CLASS="cinput"><INPUT TYPE="TEXT" CLASS="cinput" NAME="subj" SIZE=65 MAXLENGTH=255
VALUE=""></SPAN>
</TD></TR>
<TR VALIGN=MIDDLE><TD ALIGN=LEFT CLASS="cinput">
<TEXTAREA NAME="pb" WRAP=HARD ROWS=7 COLS=80></TEXTAREA>
</TD></TR>
<TR VALIGN=MIDDLE><TD ALIGN=LEFT CLASS="content"><util:button id="send" type="input"/></TR>
</TABLE>
<span class="cinput"><input type="text" class="cinput" name="subj"
size="65" maxlength="255" value="" /></span>
</td></tr>
<tr valign="middle"><td align="left" class="cinput">
<textarea name="pb" wrap="hard" rows="7" cols="80"></textarea>
</td></tr>
<tr valign="middle"><td align="left" class="content"><util:button id="send" type="input"/></td></tr>
</table>
</util:form>
<% } // end if %>
<%-- EOF --%>