<?php
require "admin_globals.php";
require "admin_check.php";
$bbsarray=array(
'dz20' => 'Discuz!2.0',
'dz22' => 'Discuz!2.2',
'pw20' => 'phpwind2.0',
'ip13' => 'IPB1.3',
'pb208' => 'PHPBB2.0.8',
'vbb23' => 'VBB2.3.4',
);
function checked($str1,$str2)
{
if ($str1==$str2)
{
$info = "checked";
}
else
{
$info = "";
}
return $info;
}
function namedir($str)
{
switch ($str)
{
case 'search' : $return='信息查询 模板组';break;
case 'common' : $return='公用文件 模板组';break;
case 'company' : $return='企业用户控制 模板组';break;
case 'personal' : $return='个人用户控制 模板组';break;
case 'html' : $return='生成html文件模板组 模板组';break;
case 'view' : $return='信息详情 模板组';break;
case 'header' : $return='静态文件 头体 模板组';break;
case 'center' : $return='静态文件 主体 模板组';break;
case 'footer' : $return='静态文件 脚体 模板组';break;
}
return $return;
}
function write_yes($filename)
{
$return=!file_exists($filename) ? $filename.' <font color=\'#ff0000\'>不存在,请通过 FTP 上传此文件.</font>' : (!is_writable($filename) ? $filename.' <font color=\'#ff0000\'>不可写,请通过 FTP 将此文件属性设成 0777 可写.</font>' : ' <font color=\'#6699cc\'>成功</font>');
return $return;
}
?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="robots" content="index,follow">
<meta name="keywords" content="毕业生,毕业生就业,毕业生找工作,大学生论坛,培训,测评,素质测评,人才资讯,毕业生,兼职,人才、管理论坛,广告....好工作、好人才 尽在大河人才网">
<meta name="generator" content="毕业生,毕业生就业,毕业生找工作,大学生论坛,培训,测评,素质测评,人才资讯,毕业生,兼职,人才、管理论坛,广告....好工作、好人才 尽在大河人才网">
<meta name="description" content="J_Space - Powered by 158jobs.com 寂寞游侠">
<meta name="MSSmartTagsPreventParsing" content="TRUE">
<meta http-equiv="MSThemeCompatible" content="Yes">
<title><?php echo $webtitle;?></title>
<link href="images/style.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style1 {
color: #FF0000;
font-weight: bold;
}
-->
</style>
</head>
<body>
<table width="95%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="18" height="16" align="right" valign="bottom"><img src="images/left_top.gif" width="18" height="16"></td>
<td align="center" valign="bottom" background="images/row_top.gif"></td>
<td width="14" align="left" valign="bottom"><img src="images/right_top.gif" width="14" height="16"></td>
</tr>
<tr>
<td align="right" background="images/left_bg.gif"> </td>
<td align="center" valign="middle" background="images/main_bg.gif">
<?
if ($HTTP_POST_VARS['save_config'])
{
if (!is_writeable('../config.inc.php')) {echo clickback('config.inc.php 文件没有可写入的权限!');}
else
{
$tablepre=addslashes($HTTP_POST_VARS['tablepre']);
$bbstype = addslashes($HTTP_POST_VARS['bbstype']);
$bbspre=addslashes($HTTP_POST_VARS['bbspre']);
$adminemail=addslashes($HTTP_POST_VARS['adminemail']);
$webtitle=addslashes($HTTP_POST_VARS['webtitle']);
$cookpath=addslashes($HTTP_POST_VARS['cookpath']);
$cookdomain=addslashes($HTTP_POST_VARS['cookdomain']);
$fp = fopen('../config.inc.php', 'r');
$configfile = fread($fp, filesize('../config.inc.php'));
fclose($fp);
$configfile = preg_replace("/[$]tablepre\s*\=\s*[\"'].*?[\"']/is", "\$tablepre = '$tablepre'", $configfile);
$configfile = preg_replace("/[$]bbstype\s*\=\s*[\"'].*?[\"']/is", "\$bbstype = '$bbstype'", $configfile);
$configfile = preg_replace("/[$]bbspre\s*\=\s*[\"'].*?[\"']/is", "\$bbspre = '$bbspre'", $configfile);
$configfile = preg_replace("/[$]adminemail\s*\=\s*[\"'].*?[\"']/is", "\$adminemail = '$adminemail'", $configfile);
$configfile = preg_replace("/[$]webtitle\s*\=\s*[\"'].*?[\"']/is", "\$webtitle = '$webtitle'", $configfile);
$configfile = preg_replace("/[$]cookpath\s*\=\s*[\"'].*?[\"']/is", "\$cookpath = '$cookpath'", $configfile);
$configfile = preg_replace("/[$]cookdomain\s*\=\s*[\"'].*?[\"']/is", "\$cookdomain = '$cookdomain'", $configfile);
$fp = fopen('../config.inc.php', 'w');
fwrite($fp, trim($configfile));
fclose($fp);
echo refreshback('操作成功');
echo showmsg('config.php?action=config','2');
echo endhtml();
echo wwwwanenet();
exit;
}
}
else if ($HTTP_POST_VARS['save_env'])
{
if (!is_writeable('../common/system.php')) {echo clickback('../common/system.php 文件不可写');exit;}
else
{
$tpldir = $HTTP_POST_VARS['tpldir'];
$htmltpldir = $HTTP_POST_VARS['htmltpldir'];
$imgdir = $HTTP_POST_VARS['imgdir'];
$htmlroot = $HTTP_POST_VARS['htmlroot'];
$charset = $HTTP_POST_VARS['charset'];
$tablewidth = $HTTP_POST_VARS['tablewidth'];
$gzip_info = $HTTP_POST_VARS['gzip_info'];
$process_info = $HTTP_POST_VARS['process_info'];
$online_info = $HTTP_POST_VARS['online_info'];
$onlinetime = $HTTP_POST_VARS['onlinetime'];
$mailreg = $HTTP_POST_VARS['mailreg'];
$cookieway = $HTTP_POST_VARS['cookieway'];
$cookietime = $HTTP_POST_VARS['cookietime'];
$sendjob_time = $HTTP_POST_VARS['sendjob_time'];
$sendfind_time = $HTTP_POST_VARS['sendfind_time'];
$sendhunterjob_time = $HTTP_POST_VARS['sendhunterjob_time'];
$sendhunterfind_time = $HTTP_POST_VARS['sendhunterfind_time'];
$sign_putfind = $HTTP_POST_VARS['sign_putfind'];
$sign_putjob = $HTTP_POST_VARS['sign_putjob'];
$sign_comhunter = $HTTP_POST_VARS['sign_comhunter'];
$sign_perhunter = $HTTP_POST_VARS['sign_perhunter'];
$sign_pxschool = $HTTP_POST_VARS['sign_pxschool'];
$sign_lesson = $HTTP_POST_VARS['sign_lesson'];
$fp = fopen('../common/system.php', 'r');
$configfile = fread($fp, filesize('../common/system.php'));
fclose($fp);
$configfile = preg_replace("/[$]tpldir\s*\=\s*[\"'].*?[\"']/is", "\$tpldir = '$tpldir'", $configfile);
$configfile = preg_replace("/[$]htmltpldir\s*\=\s*[\"'].*?[\"']/is", "\$htmltpldir = '$htmltpldir'", $configfile);
$configfile = preg_replace("/[$]imgdir\s*\=\s*[\"'].*?[\"']/is", "\$imgdir = '$imgdir'", $configfile);
$configfile = preg_replace("/[$]htmlroot\s*\=\s*[\"'].*?[\"']/is", "\$htmlroot = '$htmlroot'", $configfile);
$configfile = preg_replace("/[$]charset\s*\=\s*[\"'].*?[\"']/is", "\$charset = '$charset'", $configfile);
$configfile = preg_replace("/[$]tablewidth\s*\=\s*[\"'].*?[\"']/is", "\$tablewidth = '$tablewidth'", $configfile);
$configfile = preg_replace("/[$]gzip_info\s*\=\s*[\"'].*?[\"']/is", "\$gzip_info = '$gzip_info'", $configfile);
$configfile = preg_replace("/[$]process_info\s*\=\s*[\"'].*?[\"']/is", "\$process_info = '$process_info'", $configfile);
$configfile = preg_replace("/[$]online_info\s*\=\s*[\"'].*?[\"']/is", "\$online_info = '$online_info'", $configfile);
$configfile = preg_replace("/[$]onlinetime\s*\=\s*[\"'].*?[\"']/is", "\$onlinetime = '$onlinetime'", $configfile);
$configfile = preg_replace("/[$]mailreg\s*\=\s*[\"'].*?[\"']/is", "\$mailreg = '$mailreg'", $configfile);
$configfile = preg_replace("/[$]cookieway\s*\=\s*[\"'].*?[\"']/is", "\$cookieway = '$cookieway'", $configfile);
$configfile = preg_replace("/[$]cookietime\s*\=\s*[\"'].*?[\"']/is", "\$cookietime = '$cookietime'", $configfile);
$configfile = preg_replace("/[$]sendjob_time\s*\=\s*[\"'].*?[\"']/is", "\$sendjob_time = '$sendjob_time'", $configfile);
$configfile = preg_replace("/[$]sendfind_time\s*\=\s*[\"'].*?[\"']/is", "\$sendfind_time = '$sendfind_time'", $configfile);
$configfile = preg_replace("/[$]sendhunterjob_time\s*\=\s*[\"'].*?[\"']/is", "\$sendhunterjob_time = '$sendhunterjob_time'", $configfile);
$configfile = preg_replace("/[$]sendhunterfind_time\s*\=\s*[\"'].*?[\"']/is", "\$sendhunterfind_time = '$sendhunterfind_time'", $config