sidebar.jsp

来自「Jive是基于JSP/JAVA技术构架的一个大型BBS论坛系统,这是Jive论坛」· JSP 代码 · 共 69 行

JSP
69
字号
<%  // sidebar variables        String[] sidebarItems = {        "Install Checklist",        "Language",        "Database",        "Admin Setup"    };    String[] links = {        "index.jsp",        "setup2.jsp",        "setup3.jsp",        "setup5.jsp"    };    boolean[] sidebarActive = new boolean[4];    for (int i=0; i<sidebarActive.length; i++) {        sidebarActive[i] = getSessionBoolean(session,"sidebar."+i+".active");    }    String[] lights = new String[4];    for (int i=0; i<lights.length; i++) {        String temp = getSessionString(session,"sidebar."+i+".light");        if (temp == null) {            temp = RED;        }        lights[i] = temp;    }%><center><font size="-2">Install Status</font></center><p><%  for (int i=0; i<sidebarItems.length; i++) {        boolean link = lights[i].equals(YELLOW) || lights[i].equals(GREEN);        String bgcolor = "";        if (sidebarActive[i]) {            bgcolor = "#999999";        }        else {            bgcolor = "#cccccc";        }%><table bgcolor="<%= bgcolor %>" cellpadding="0" cellspacing="0" border="0" width="160"><tr>    <td>    <table bgcolor="<%= bgcolor %>" cellpadding="3" cellspacing="1" border="0" width="100%">    <tr bgcolor="#eeeeee">        <td width="1%"><%= lights[i] %></td>        <td width="99%" background="images/grad_gray.gif">        <%  if (sidebarActive[i]) { %>            <font size="-1" color="#666666">        <%  } else { %>            <font size="-1">        <%  } %>        <%  if (link) { %>            <a href="<%= links[i] %>"><b><%= sidebarItems[i] %></b></a>        <%  } else { %>            <b><%= sidebarItems[i] %></b>        <%  } %>            </font>        </td>    </tr>    </table>    </td></tr></table><p><%  } %>

⌨️ 快捷键说明

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