<commit_before><html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=${encoding}">
<meta http-equiv="Content-Style-Type" content="text/css">
<title>Welcome to JForum ${version} Installation</title>
<link rel="stylesheet" href="${contextPath}/templates/default/styles/style.css" type="text/css">
<style type="text/css">
th			{ background-image: url('${contextPath}/templates/default/images/cellpic3.gif') }
td.cat		{ background-image: url('${contextPath}/templates/default/images/cellpic1.gif') }
td.rowpic	{ background-image: url('${contextPath}/templates/default/images/cellpic2.jpg'); background-repeat: repeat-y }
td.cathead,td.catsides,td.catleft,td.catright,td.catbottom { background-image: url('${contextPath}/templates/default/images/cellpic1.gif') }
</style>

<script language="javascript">
function validateForm()
{
	var status = checkDatabase();
	status = status && checkBoard();
	return status;
}

function checkBoard()
{
	var f = document.install;
	var s = "";

	if (f.forum_link.value == "") {
		s += "${I18n.getMessage("Install.domainName")} ${I18n.getMessage("Install.isEmpty")}\n";
	}

	if (f.admin_pass1.value == "") {
		s += "${I18n.getMessage("Administrator")} ${I18n.getMessage("User.password")} ${I18n.getMessage("Install.isEmpty")}\n";
	}

	if (f.admin_pass1.value != f.admin_pass2.value) {
		s += "${I18n.getMessage("Administrator")} ${I18n.getMessage("User.password")} ${I18n.getMessage("Install.confirmationNotMatch")}\n";
	}

	if (s != "") {
		alert("${I18n.getMessage("Install.issuesFound")}: \n\n" + s + "\n${I18n.getMessage("Install.pleaseCorrect")}");
		return false;
	}

	return true;
}

function checkDatabase()
{
	var f = document.install;
	var s = "";
  
	if (f.db_connection_type.selectedIndex == 0) {  // native selected
		if (f.dbpasswd.value != f.dbpasswd_confirm.value) {
			alert("${I18n.getMessage("Install.dbPasswdNotMatch")}");
			return false;
		}    
		
		if (f.database.value != "hsqldb") {
			if (f.dbuser.value == "") {
				s += "${I18n.getMessage("Install.dbUsername")} ${I18n.getMessage("Install.isEmpty")}\n";
			}
    
			if (f.dbpasswd.value == "") {
				s += "${I18n.getMessage("Install.dbPassword")} ${I18n.getMessage("Install.isEmpty")}\n";
			}

			if (f.dbport.value == "") {
				s += "${I18n.getMessage("Install.dbPort")} ${I18n.getMessage("Install.isEmpty")}\n";
			}
		}
		else {
			if (f.dbpasswd.value == "" || f.dbuser.value == "") {
				if (confirm("${I18n.getMessage("Install.hsqldbDefault")}. \n${I18n.getMessage("Install.jforumUseDefault")}")) {
					return true;
				}
    
				return false;
			}
		}
	} 
	else {
		if (f.dbdatasource.value == "") {
			s += "${I18n.getMessage("Install.dbDataSource")} ${I18n.getMessage("Install.isEmpty")}\n";
		}
	}
	
	if (s != "") {
		if (confirm("${I18n.getMessage("Install.dbIssues")}: \n\n" + s + "\n${I18n.getMessage("Install.dbMayResultError")}")) {
			return true;
		}
		
		return false;
	}

	return true;
}

function changeDbPort(dbName)
{
	var port = document.install.dbport;

	if (dbName == "mysql") port.value = 3306;
	else if (dbName == "oracle") port.value = 1521;
	else if (dbName == "postgresql") port.value = 5432;
	else if (dbName == "hsqldb") { 
		port.value = "";
		port.enabled = false;
	}
}
</script>
</head>
<body text="#000000" link="#006699" vlink="#5584AA">

<table width="70%" height="100%" align="center">
<tr>
<td valign="middle" align="center">

<table width="100%" border="0" cellspacing="0" cellpadding="10" align="center"> 
	<tr>
		<td class="bodyline" width="100%"><table width="100%" border="0" cellspacing="0" cellpadding="0">

			<tr>
				<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
					<tr>
						<td><img src="${contextPath}/templates/default/images/logo.jpg" border="0" alt="JForum" vspace="1" /></td>
						<td align="center" width="100%" valign="middle"><span class="maintitle">${I18n.getMessage("Install.welcome")} JForum ${version} ${I18n.getMessage("Install.installation")}</span></td>
					</tr>
				</table></td>
			</tr>

			<tr>
				<td align="center"><br /><br /></td>
			</tr>
			<tr>
				<td colspan="2"><table width="90%" border="0" align="center" cellspacing="0" cellpadding="0">
					<tr>
						<td>
							<span class="gen">
							${I18n.getMessage("Install.welcomeMessage")}
							<br/></br>
							${I18n.getMessage("Install.forHelpAccess")} <a href="http://www.jforum.net/install.htm">http://www.jforum.net/install.htm</a>
							<p align="center">${I18n.getMessage("Install.notPerfect")}</p>
							</span>
						</td>
					</tr>

				</table></td>
			</tr>
			<tr>
				<td align="center" valign="middle"><br/><span class="maintitle">${I18n.getMessage("Install.step1")}</span></td>
			</tr>
			<tr>
				<td width="100%"><table width="100%" cellpadding="2" cellspacing="1" border="0" class="forumline">
				<form action="${JForumContext.encodeURL("/install/install")}" name="install" method="post" onSubmit="return validateForm();">
				<input type="hidden" name="module" value="install">
				<input type="hidden" name="action" value="checkInformation">
					<tr>
						<th colspan="2">1) ${I18n.getMessage("Install.general")}</th>

					</tr>
					<tr>
						<td class="row3" align="right" width="40%"><span class="gen"><b>${I18n.getMessage("Install.boardLanguage")}:</b> </span></td>
						<td class="row3">
							<select name="language" onChange="document.location = '${contextPath}/install/install${extension}?module=install&action=welcome&l=' + this.value;">
								<option value="en_US" <#if language?default("") == "en_US">selected</#if>>English American (en_US)</option>
								<option value="zh_TW" <#if language?default("") == "zh_TW">selected</#if>>Chinese Traditional (zh_TW)</option>
								<!--<option value="zh_CN" <#if language?default("") == "zh_CN">selected</#if>>Chinese Simplifed (zh_CN)</option>-->
								<!--<option value="fr_FR" <#if language?default("") == "fr_FR">selected</#if>>French (fr_FR)</option>-->
								<option value="de_DE" <#if language?default("") == "de_DE">selected</#if>>German (de_DE)</option><commit_msg>Submitted by:  <NAME> Enable zh_CN language interface in installer.<commit_after><html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=${encoding}">
<meta http-equiv="Content-Style-Type" content="text/css">
<title>Welcome to JForum ${version} Installation</title>
<link rel="stylesheet" href="${contextPath}/templates/default/styles/style.css" type="text/css">
<style type="text/css">
th			{ background-image: url('${contextPath}/templates/default/images/cellpic3.gif') }
td.cat		{ background-image: url('${contextPath}/templates/default/images/cellpic1.gif') }
td.rowpic	{ background-image: url('${contextPath}/templates/default/images/cellpic2.jpg'); background-repeat: repeat-y }
td.cathead,td.catsides,td.catleft,td.catright,td.catbottom { background-image: url('${contextPath}/templates/default/images/cellpic1.gif') }
</style>

<script language="javascript">
function validateForm()
{
	var status = checkDatabase();
	status = status && checkBoard();
	return status;
}

function checkBoard()
{
	var f = document.install;
	var s = "";

	if (f.forum_link.value == "") {
		s += "${I18n.getMessage("Install.domainName")} ${I18n.getMessage("Install.isEmpty")}\n";
	}

	if (f.admin_pass1.value == "") {
		s += "${I18n.getMessage("Administrator")} ${I18n.getMessage("User.password")} ${I18n.getMessage("Install.isEmpty")}\n";
	}

	if (f.admin_pass1.value != f.admin_pass2.value) {
		s += "${I18n.getMessage("Administrator")} ${I18n.getMessage("User.password")} ${I18n.getMessage("Install.confirmationNotMatch")}\n";
	}

	if (s != "") {
		alert("${I18n.getMessage("Install.issuesFound")}: \n\n" + s + "\n${I18n.getMessage("Install.pleaseCorrect")}");
		return false;
	}

	return true;
}

function checkDatabase()
{
	var f = document.install;
	var s = "";
  
	if (f.db_connection_type.selectedIndex == 0) {  // native selected
		if (f.dbpasswd.value != f.dbpasswd_confirm.value) {
			alert("${I18n.getMessage("Install.dbPasswdNotMatch")}");
			return false;
		}    
		
		if (f.database.value != "hsqldb") {
			if (f.dbuser.value == "") {
				s += "${I18n.getMessage("Install.dbUsername")} ${I18n.getMessage("Install.isEmpty")}\n";
			}
    
			if (f.dbpasswd.value == "") {
				s += "${I18n.getMessage("Install.dbPassword")} ${I18n.getMessage("Install.isEmpty")}\n";
			}

			if (f.dbport.value == "") {
				s += "${I18n.getMessage("Install.dbPort")} ${I18n.getMessage("Install.isEmpty")}\n";
			}
		}
		else {
			if (f.dbpasswd.value == "" || f.dbuser.value == "") {
				if (confirm("${I18n.getMessage("Install.hsqldbDefault")}. \n${I18n.getMessage("Install.jforumUseDefault")}")) {
					return true;
				}
    
				return false;
			}
		}
	} 
	else {
		if (f.dbdatasource.value == "") {
			s += "${I18n.getMessage("Install.dbDataSource")} ${I18n.getMessage("Install.isEmpty")}\n";
		}
	}
	
	if (s != "") {
		if (confirm("${I18n.getMessage("Install.dbIssues")}: \n\n" + s + "\n${I18n.getMessage("Install.dbMayResultError")}")) {
			return true;
		}
		
		return false;
	}

	return true;
}

function changeDbPort(dbName)
{
	var port = document.install.dbport;

	if (dbName == "mysql") port.value = 3306;
	else if (dbName == "oracle") port.value = 1521;
	else if (dbName == "postgresql") port.value = 5432;
	else if (dbName == "hsqldb") { 
		port.value = "";
		port.enabled = false;
	}
}
</script>
</head>
<body text="#000000" link="#006699" vlink="#5584AA">

<table width="70%" height="100%" align="center">
<tr>
<td valign="middle" align="center">

<table width="100%" border="0" cellspacing="0" cellpadding="10" align="center"> 
	<tr>
		<td class="bodyline" width="100%"><table width="100%" border="0" cellspacing="0" cellpadding="0">

			<tr>
				<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
					<tr>
						<td><img src="${contextPath}/templates/default/images/logo.jpg" border="0" alt="JForum" vspace="1" /></td>
						<td align="center" width="100%" valign="middle"><span class="maintitle">${I18n.getMessage("Install.welcome")} JForum ${version} ${I18n.getMessage("Install.installation")}</span></td>
					</tr>
				</table></td>
			</tr>

			<tr>
				<td align="center"><br /><br /></td>
			</tr>
			<tr>
				<td colspan="2"><table width="90%" border="0" align="center" cellspacing="0" cellpadding="0">
					<tr>
						<td>
							<span class="gen">
							${I18n.getMessage("Install.welcomeMessage")}
							<br/></br>
							${I18n.getMessage("Install.forHelpAccess")} <a href="http://www.jforum.net/install.htm">http://www.jforum.net/install.htm</a>
							<p align="center">${I18n.getMessage("Install.notPerfect")}</p>
							</span>
						</td>
					</tr>

				</table></td>
			</tr>
			<tr>
				<td align="center" valign="middle"><br/><span class="maintitle">${I18n.getMessage("Install.step1")}</span></td>
			</tr>
			<tr>
				<td width="100%"><table width="100%" cellpadding="2" cellspacing="1" border="0" class="forumline">
				<form action="${JForumContext.encodeURL("/install/install")}" name="install" method="post" onSubmit="return validateForm();">
				<input type="hidden" name="module" value="install">
				<input type="hidden" name="action" value="checkInformation">
					<tr>
						<th colspan="2">1) ${I18n.getMessage("Install.general")}</th>

					</tr>
					<tr>
						<td class="row3" align="right" width="40%"><span class="gen"><b>${I18n.getMessage("Install.boardLanguage")}:</b> </span></td>
						<td class="row3">
							<select name="language" onChange="document.location = '${contextPath}/install/install${extension}?module=install&action=welcome&l=' + this.value;">
								<option value="en_US" <#if language?default("") == "en_US">selected</#if>>English American (en_US)</option>
								<option value="zh_TW" <#if language?default("") == "zh_TW">selected</#if>>Chinese Traditional (zh_TW)</option>
								<option value="zh_CN" <#if language?default("") == "zh_CN">selected</#if>>Chinese Simplifed (zh_CN)</option>
								<!--<option value="fr_FR" <#if language?default("") == "fr_FR">selected</#if>>French (fr_FR)</option>-->
								<option value="de_DE" <#if language?default("") == "de_DE">selected</#if>>German (de_DE)</option>
{'fraction_non_alphanumeric': 0.22307123490263742, 'fraction_numerical': 0.024977405307698628, 'mean_word_length': 4.475483580746738, 'pattern_counts': {'":': 0, '<': 217, '<?xml version=': 0, '>': 217, 'https://': 0, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6587375', 'n_tokens_mistral': 5047, 'n_tokens_neox': 4312, 'n_words': 685}