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

📄 configmvncore.jsp

📁 解觖java技术中后台无法上传数给的情况
💻 JSP
📖 第 1 页 / 共 2 页
字号:
<%--
 - $Header: /cvsroot/mvnforum/mvnforum/srcweb/mvnplugin/mvnforum/admin/configmvncore.jsp,v 1.8 2006/04/14 18:02:17 minhnn Exp $
 - $Author: minhnn $
 - $Revision: 1.8 $
 - $Date: 2006/04/14 18:02:17 $
 -
 - ====================================================================
 -
 - Copyright (C) 2002-2006 by MyVietnam.net
 -
 - All copyright notices regarding mvnForum MUST remain 
 - intact in the scripts and in the outputted HTML.
 - The "powered by" text/logo with a link back to
 - http://www.mvnForum.com and http://www.MyVietnam.net in 
 - the footer of the pages MUST remain visible when the pages
 - are viewed on the internet or intranet.
 -
 - This program is free software; you can redistribute it and/or modify
 - it under the terms of the GNU General Public License as published by
 - the Free Software Foundation; either version 2 of the License, or
 - any later version.
 -
 - This program is distributed in the hope that it will be useful,
 - but WITHOUT ANY WARRANTY; without even the implied warranty of
 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 - GNU General Public License for more details.
 -
 - You should have received a copy of the GNU General Public License
 - along with this program; if not, write to the Free Software
 - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 -
 - Support can be obtained from support forums at:
 - http://www.mvnForum.com/mvnforum/index
 -
 - Correspondence and Marketing Questions can be sent to:
 - info at MyVietnam net
 -
 - @author: Minh Nguyen  
 - @author: Mai  Nguyen  
 --%>
<%@ page contentType="text/html;charset=utf-8" %>
<%@ page errorPage="fatalerror.jsp"%>
<%@ page import="net.myvietnam.mvncore.util.DateUtil" %>
<%@ page import="net.myvietnam.mvncore.configuration.DOM4JConfiguration" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<%@ include file="inc_common.jsp"%>
<fmt:bundle basename="mvnForum_i18n">
<html>
<head>
  <title><fmt:message key="mvnforum.common.forum.title_name"/> - Config mvnCore</title>
<%@ include file="/mvnplugin/mvnforum/meta.jsp"%>
<link href="<%=onlineUser.getCssPath()%>" rel="stylesheet" type="text/css">
</head>
<body leftmargin="0" topmargin="0">
<%@ include file="inc_js_checkvalid_myvietnamlib.jsp"%>

<script type="text/javascript">
function SubmitForm() {
  if (ValidateForm() == true ) {
    document.submitform.submitbutton.disabled = true;
    document.submitform.submit();
  }
}

function ValidateForm() {
  if (document.submitform.use_datasource.options[document.submitform.use_datasource.selectedIndex].value == "false") {
    if (isBlank(document.submitform.database_type, "database_type")) return false;
    if (isBlank(document.submitform.driver_class_name, "driver_class_name")) return false;
    if (isBlank(document.submitform.database_url, "database_url")) return false;
    if (isBlank(document.submitform.database_user, "database_user")) return false;
    if (!isUnsignedInteger(document.submitform.max_connection, "max_connection")) return false;
    if (!isUnsignedInteger(document.submitform.max_time_to_wait, "max_time_to_wait")) return false;
    if (!isUnsignedInteger(document.submitform.minutes_between_refresh, "minutes_between_refresh")) return false;
  } else {
    if (isBlank(document.submitform.datasource_name, "datasource_name")) return false;
  }

  if (isBlank(document.submitform.mail_server, "mail_server")) return false;
  if (isBlank(document.submitform.default_mail_from, "default_mail_from")) return false;
  if (!isEmail(document.submitform.default_mail_from, "default_mail_from")) return false;
  if (!isUnsignedInteger(document.submitform.port, "port")) return false;

  if (isBlank(document.submitform.server_path, "server_path")) return false;
  if (isBlank(document.submitform.server_hour_offset, "server_hour_offset")) return false;
  //if (!isUnsignedInteger(document.submitform.server_hour_offset, "server_hour_offset")) return false;
  return true;
}
function OnChangeUseDatasource() {
  if (document.submitform.use_datasource.options[document.submitform.use_datasource.selectedIndex].value == "false") {
    document.getElementById("id_driver_class_name").style.display = '';
    document.getElementById("id_database_url").style.display = '';
    document.getElementById("id_database_user").style.display = '';
    document.getElementById("id_database_password").style.display = '';
    document.getElementById("id_max_connection").style.display = '';
    document.getElementById("id_max_time_to_wait").style.display = '';
    document.getElementById("id_minutes_between_refresh").style.display = '';
    document.getElementById("id_datasource_name").style.display = 'none';
  } else {
    document.getElementById("id_driver_class_name").style.display = 'none';
    document.getElementById("id_database_url").style.display = 'none';
    document.getElementById("id_database_user").style.display = 'none';
    document.getElementById("id_database_password").style.display = 'none';
    document.getElementById("id_max_connection").style.display = 'none';
    document.getElementById("id_max_time_to_wait").style.display = 'none';
    document.getElementById("id_minutes_between_refresh").style.display = 'none';
    document.getElementById("id_datasource_name").style.display = '';
  }
}
function OnChangeUseMailsource() {
  if (document.submitform.use_mailsource.options[document.submitform.use_mailsource.selectedIndex].value == "false") {
    document.getElementById("id_mail_server").style.display = '';
    document.getElementById("id_username").style.display = '';
    document.getElementById("id_password").style.display = '';
    document.getElementById("id_port").style.display = '';
    document.getElementById("id_mailsource_name").style.display = 'none';
  } else {
    document.getElementById("id_mail_server").style.display = 'none';
    document.getElementById("id_username").style.display = 'none';
    document.getElementById("id_password").style.display = 'none';
    document.getElementById("id_port").style.display = 'none';
    document.getElementById("id_mailsource_name").style.display = '';
  }
}
</script>

<%@ include file="header.jsp"%>
<br/>
<%
DOM4JConfiguration mvncoreConfig  = (DOM4JConfiguration)request.getAttribute("mvncoreConfig");
%>

<table width="98%" align="center">
  <tr class="nav">
    <td><img src="<%=contextPath%>/mvnplugin/mvnforum/images/nav.gif"></td>
    <td width="100%" nowrap>
    <a class="nav" href="<%=urlResolver.encodeURL(request, response, "index", URLResolver.RENDER_URL, "view")%>"><fmt:message key="mvnforum.common.nav.index"/></a>&nbsp;&raquo;&nbsp;
    <a class="nav" href="<%=urlResolver.encodeURL(request, response, "index")%>"><fmt:message key="mvnforum.admin.index.title_name"/><!--Admin CP--></a>&nbsp;&raquo;&nbsp;
    <a class="nav" href="<%=urlResolver.encodeURL(request, response, "configindex")%>">Config mvnForum</a>&nbsp;&raquo;&nbsp;
    Config mvnCore
    </td>
  </tr>
</table>
<br/>

<form action="<%=urlResolver.encodeURL(request, response, "configmvncoreprocess", URLResolver.ACTION_URL)%>" method="post" name="submitform">
<%=urlResolver.generateFormAction(request, response, "configmvncoreprocess")%>
<table class="tborder" width="98%" cellspacing="1" cellpadding="3" align="center">
  <tr class="portlet-section-header">
    <td colspan="2">Configuration mvnCore - Plugin Options</td>
  </tr>
  <tr class="portlet-section-body">
    <td>enable_mvnforum <span class="requiredfield">*</span></td>
    <td>
    <select name="enable_mvnforum">
    <% String enable_mvnforum = mvncoreConfig.getString("plugin_options.enable_mvnforum", "");%>
      <option value="true" <%if ("true".equals(enable_mvnforum) ) { %> selected <% } %> >true</option>
      <option value="false" <%if ("false".equals(enable_mvnforum) ) { %> selected <% } %>>false</option>
    </select>
    </td>
  </tr>
  <tr class="portlet-section-alternate">
    <td>enable_mvncms <span class="requiredfield">*</span></td>
    <td>
    <select name="enable_mvncms">
    <% String enable_mvncms = mvncoreConfig.getString("plugin_options.enable_mvncms", "");%>
      <option value="true" <%if ("true".equals(enable_mvncms) ) { %> selected <% } %> >true</option>
      <option value="false" <%if ("false".equals(enable_mvncms) ) { %> selected <% } %>>false</option>
    </select>
    </td>
  </tr>

  <tr class="portlet-section-header">
    <td colspan="2">Configuration mvnCore - Database Configuration</td>
  </tr>
  <tr class="portlet-section-body" id="id_database_type">
    <td>database_type <span class="requiredfield">*</span></td>
    <td>
    <select name="database_type">
      <% String database_type = mvncoreConfig.getString("dboptions.database_type", "");%>
      <option value=0 <%= (database_type.equals("0")) ? "selected" : "" %>>Default (Auto detect)</option>
      <option value=2 <%= (database_type.equals("2")) ? "selected" : "" %>>Database/Driver doesn't support scrollable Resultset</option>
    </select>
    </td>
  </tr>
  <tr class="portlet-section-alternate">
    <td>use_datasource <span class="requiredfield">*</span></td>
    <td>
    <select name="use_datasource" onChange="javascript:OnChangeUseDatasource();">
    <% String use_datasource = mvncoreConfig.getString("dboptions.use_datasource", "");%>
      <option value="true" <%if ("true".equals(use_datasource) ) { %> selected <% } %> >true</option>
      <option value="false" <%if ("false".equals(use_datasource) ) { %> selected <% } %>>false</option>
    </select>
    </td>
  </tr>
  <tr class="portlet-section-body" id="id_driver_class_name">
    <td>driver_class_name <span class="requiredfield">*</span></td>
    <td><input type="text" size="70" name="driver_class_name" value="<%=mvncoreConfig.getString("dboptions.driver_class_name", "")%>"></td>
  </tr>
  <tr class="portlet-section-alternate" id="id_database_url">
    <td>database_url <span class="requiredfield">*</span></td>
    <td><input type="text" size="70" name="database_url" value="<%=mvncoreConfig.getString("dboptions.database_url", "")%>"></td>
  </tr>
  <tr class="portlet-section-body" id="id_database_user">
    <td>database_user <span class="requiredfield">*</span></td>
    <td><input type="text" size="70" name="database_user" value="<%=mvncoreConfig.getString("dboptions.database_user", "")%>"></td>
  </tr>
  <tr class="portlet-section-alternate" id="id_database_password">
    <td>database_password</td>

⌨️ 快捷键说明

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