venice-main-classic/web/format/comm/profile.jsp

125 lines
5.5 KiB
Plaintext

<%--
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 <http://www.mozilla.org/MPL/>.
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 <erbo@users.sf.net>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
<%@ page import = "com.silverwrist.util.StringUtil" %>
<%@ page import = "com.silverwrist.venice.core.*" %>
<%@ page import = "com.silverwrist.venice.ui.view.FindView" %>
<%@ page import = "com.silverwrist.venice.ui.view.JSPView" %>
<%@ taglib uri="/tlds/util" prefix="util" %>
<%@ taglib uri="/tlds/global" prefix="global" %>
<%@ taglib uri="/tlds/user" prefix="user" %>
<%@ taglib uri="/tlds/community" prefix="comm" %>
<%
JSPView view = JSPView.get(request);
CommunityContext comm = view.getCommunity();
String tmp;
%>
<util:comment>Profile for community #<comm:ID/></util:comment>
<util:header title="Community Profile:">
<util:subtitle><util:escape><%= comm.getName() %></util:escape></util:subtitle>
</util:header>
<table border="0" cellpadding="6" cellspacing="0"><tr valign="top">
<td align="left" class="c2"><util:font color="content.fg" size="profile-dates">
<%= view.getRequestAttribute("community.logo").toString() %><br />
<% java.util.Date tmpd = comm.getCreationDate(); %>
<% if (tmpd!=null) { %>
Community created:<br /><util:escape><%= view.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<% tmpd = comm.getLastAccessDate(); %>
<% if (tmpd!=null) { %>
Last accessed:<br /><util:escape><%= view.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<% tmpd = comm.getLastUpdateDate(); %>
<% if (tmpd!=null) { %>
Profile last updated:<br /><util:escape><%= view.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<user:is_logged_in>
<div align="center">
<comm:can_join>
<util:xlink>
<util:href type="servlet">comm/join.js.vs?cc=<comm:ID/></util:href>
<util:text><util:button id="join_now"/></util:text>
</util:xlink>
</comm:can_join>
<comm:cannot_join>
<comm:can_send_invite>
<util:xlink>
<util:href type="servlet">comm/invite.js.vs?cc=<comm:ID/></util:href>
<util:text><util:button id="invite"/></util:text>
</util:xlink>
</comm:can_send_invite>
</comm:cannot_join>
</div>
</user:is_logged_in>
</util:font></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<comm:is_public><b><u>Public Community</u></b></comm:is_public>
<comm:is_private><b><u>Private Community</u></b></comm:is_private>
<global:categories_enabled>
<br />
<b>Category:</b>
<% CategoryDescriptor cat = (CategoryDescriptor)(view.getRequestAttribute("category")); %>
<% for (int i=0; i<cat.getNumLevels(); i++) { %>
<% if (i>0) { %>: <% } %>
<util:xlink aclass="content">
<util:href type="servlet">
find.js.vs?disp=<%= FindView.FD_COMMUNITIES %>&cat=<%= cat.getIDAtLevel(i) %>
</util:href>
<util:text><util:escape><%= cat.getTitleAtLevel(i) %></util:escape></util:text>
</util:xlink>
<% } // end for %>
</global:categories_enabled>
<br />
<i><util:escape><comm:synopsis/></util:escape></i><p />
<% UserProfile prof = (UserProfile)(view.getRequestAttribute("host.profile")); %>
<b>Host:</b>
<util:xlink aclass="content">
<util:href type="servlet">user/<%= prof.getUserName() %></util:href>
<util:text><%= prof.getUserName() %></util:text>
</util:xlink><br />
<% ContactInfo ci = (ContactInfo)(view.getRequestAttribute("contact.info")); %>
<b>Location:</b><br />
<% tmp = ci.getCompany(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = ci.getAddressLine1(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = ci.getAddressLine2(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = view.getRequestAttribute("address.lastline").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = view.getRequestAttribute("address.country").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<br />
<% tmp = comm.getLanguageFullName(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><b>Primary Language:</b>
<util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = comm.getRules(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><b>Standards of Conduct:</b>
<util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = ci.getURL(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><b>Homepage:</b>
<a href="<%= tmp %>" class="content"><util:escape><%= tmp %></util:escape></a><br /><% } %>
</util:font></td>
</tr></table>
<%-- EOF --%>