⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 editgroup.jsp

📁 Jive是基于JSP/JAVA技术构架的一个大型BBS论坛系统
💻 JSP
字号:
<%@ page contentType="text/html;charset=UTF-8" %>

<%
/**
 *	$RCSfile: editGroup.jsp,v $
 *	$Revision: 1.1.1.1 $
 *	$Date: 2002/09/09 13:50:11 $
 */
%>

<%@ page import="java.util.*,
                 com.jivesoftware.forum.*,
                 com.jivesoftware.forum.util.*"
    errorPage="error.jsp"
%>

<%@ include file="global.jsp" %>

<%	// get parameters
	long groupID = ParamUtils.getLongParameter(request,"group",-1L);
	String name = ParamUtils.getParameter(request,"name");
	String description = ParamUtils.getParameter(request,"description",true);
	boolean edit = ParamUtils.getBooleanParameter(request,"edit");

	// Get a group manager
	GroupManager groupManager = forumFactory.getGroupManager();

    // Load the specified group
	Group group = groupManager.getGroup(groupID);

    // Put the forum in the session (is needed by the sidebar)
    session.setAttribute("admin.sidebar.groups.currentGroupID", ""+groupID);

    // Total number of groups
    int groupCount = groupManager.getGroupCount();

	if (edit) {
        group.setName(name);
        if (description != null) {
            group.setDescription(description);
        }
        // done editing, so redirect
        response.sendRedirect("groups.jsp");
        return;
	}

    name = group.getName();
    description = group.getDescription();

    // Remove the user in the session (if we come to this page, the sidebar
    // shouldn't show the specific user options).
    session.removeAttribute("admin.sidebar.users.currentUser");
%>

<%  // special onload command to load the sidebar
    onload = " onload=\"parent.frames['sidebar'].location.href='sidebar.jsp?sidebar=users';\"";
%>
<%@ include file="header.jsp" %>

<p>

<%  // Title of this page and breadcrumbs
    String title = "编辑用户组属性";
    String[][] breadcrumbs = {
        {"主页面", "main.jsp"},
        {"用户组概览", "groups.jsp"},
        {title, "editGroup.jsp?group="+groupID}
    };
%>
<%@ include file="title.jsp" %>

<font size="-1">
Some text for this page...
</font>

<form action="editGroup.jsp" method="post">
<input type="hidden" name="group" value="<%= groupID %>">
<input type="hidden" name="edit" value="true">

<font size="-1"><b>编辑用户组</b></font>
<ul>
    <table cellpadding="3" cellspacing="0" border="0">
    <tr>
    	<td><font size="-1">用户组ID:</font></td>
    	<td><font size="-1"><%= group.getID() %></font></td>
    </tr>
    <tr>
    	<td><font size="-1">组名:</font></td>
    	<td><input type="text" name="name" value="<%= (name!=null)?name:"" %>"></td>
    </tr>
    <tr>
    	<td valign="top"><font size="-1">描述:</font></td>
    	<td><textarea cols="30" rows="5" name="description"><%= (description!=null)?description:"" %></textarea></td>
    </tr>
    <tr>
        <td><font size="-1">&nbsp;</font></td>
        <td><p><input type="submit" value="保存修改"></td>
    </table>
</ul>
</form>


</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -