venice-main-classic/web/format/user/sidebox.jsp

115 lines
4.9 KiB
Plaintext
Raw Permalink Normal View History

<%--
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 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.ui.view.JSPView" %>
<%@ taglib uri="/tlds/util" prefix="util" %>
<%
JSPView view = JSPView.get(request);
List in_list = (List)(view.getRequestAttribute("sideboxes.included"));
List out_list = (List)(view.getRequestAttribute("sideboxes.excluded"));
%>
<util:comment>User sidebox list</util:comment>
<util:header title="Your Front Page Configuration"/>
<util:font color="content.fg" size="content"><util:link href="top.js.vs" type="servlet">Return to
Front Page</util:link></util:font><P>
<% if (in_list.size()>0) { %>
<TABLE BORDER=0 ALIGN=CENTER CELLPADDING=0 CELLSPACING=3>
<% for (int i=0; i<in_list.size(); i++) { %>
<% SideBoxDescriptor d = (SideBoxDescriptor)(in_list.get(i)); %>
<TR VALIGN=MIDDLE>
<TD ALIGN=CENTER WIDTH=16>
<% if (i==(in_list.size()-1)) { %>&nbsp;<% } else { %>
<util:xlink>
<util:href type="servlet">usr/sidebox_down.js.vs?box=<%= d.getID() %></util:href>
<util:text><util:image src="icn_down.gif" fixup="true" alt="[Down]" width="16"
height="16"/></util:text>
</util:xlink>
<% } // end if %>
</TD>
<TD ALIGN=CENTER WIDTH=16>
<% if (i==0) { %>&nbsp;<% } else { %>
<util:xlink>
<util:href type="servlet">usr/sidebox_up.js.vs?box=<%= d.getID() %></util:href>
<util:text><util:image src="icn_up.gif" fixup="true" alt="[Up]" width="16"
height="16"/></util:text>
</util:xlink>
<% } // end if %>
</TD>
<TD ALIGN=CENTER WIDTH=16>
<util:xlink>
<util:href type="servlet">usr/sidebox_delete.js.vs?box=<%= d.getID() %></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">
<B><util:escape><%= d.getTitle(false) %></util:escape></B>
</util:font></TD>
</TR>
<% } // end for %>
</TABLE><P>
<TABLE BORDER=0 CELLPADDING=2 CELLSPACING=0>
<TR VALIGN=MIDDLE>
<TD ALIGN=CENTER WIDTH=16>
<util:image src="icn_down.gif" fixup="true" alt="[Down]" width="16" height="16"/>
</TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
Click this symbol to move the specified sidebox down on your Front Page.
</util:font></TD>
</TR>
<TR VALIGN=MIDDLE>
<TD ALIGN=CENTER WIDTH=16>
<util:image src="icn_up.gif" fixup="true" alt="[Up]" width="16" height="16"/>
</TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
Click this symbol to move the specified sidebox up on your Front Page.
</util:font></TD>
</TR>
<TR VALIGN=MIDDLE>
<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">
Click this symbol to remove the specified sidebox from your Front Page.
</util:font></TD>
</TR>
</TABLE>
<% } else { %>
<util:font color="content.fg" size="content"><EM>You have no sideboxes on your Front Page.</EM></util:font>
<% } // end if %>
<% if (out_list.size()>0) { %>
<P>
<util:form action="usr/sidebox_add.js.vs" type="servlet">
<DIV CLASS="content"><util:font color="content.fg" size="content">
<B>Add sidebox:</B>&nbsp;&nbsp;
<SELECT NAME="box" SIZE=1>
<% for (int i=0; i<out_list.size(); i++) { %>
<% SideBoxDescriptor d = (SideBoxDescriptor)(out_list.get(i)); %>
<OPTION VALUE="<%= d.getID() %>"><util:escape><%= d.getTitle(false) %></util:escape></OPTION>
<% } // end for %>
</SELECT>&nbsp;&nbsp;
<util:button id="add" type="input"/>
</util:font></DIV>
</util:form>
<% } // end if %>