<table width="100%" border="0" cellpadding="5" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td bgcolor="#FFFFFF"><table width="100%" border="0" cellspacing="1" cellpadding="5">
<form action="admin.php?action=doconfig"  method="post" name="" >
<tr id="cat">
	<td class="tblhead" colspan="2"><b>基本设置</b></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>BLOG 名称</b><br>显示在首页的标题栏和每页顶部</td>
	<td><input class="formfield" type="text" name="blogname" size="35" maxlength="200" value="<?php echo $config['blogname'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>BLOG 描述</b><br>关于这个Blog的简单介绍</td>
	<td><input class="formfield" type="text" name="blogdescribe" size="35" maxlength="200" value="<?php echo $config['blogdescribe'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>BLOG 的URL地址</b><br>例如:http://www.phpblog.cn/</td>
	<td><input class="formfield" type="text" name="blogurl" size="35" maxlength="200" value="<?php echo $config['blogurl'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>每页日志数</b><br>前台日志列表中每页显示的日志数</td>
	<td><input class="formfield" type="text" name="indexNum" size="35" maxlength="200" value="<?php echo $config['index_show_number'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>最新日志/评论数</b><br>前台最新日志和最新评论显示的数量</td>
	<td><input class="formfield" type="text" name="newNum" size="35" maxlength="200" value="<?php echo $config['lastblog'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>每页留言数</b><br>前台每页显示多少个留言</td>
	<td><input class="formfield" type="text" name="gbNum" size="35" maxlength="200" value="<?php echo $config['gb_show_num'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>评论/留言字符限制数</b><br>当游客可以发表的评论/留言内容最大字数,默认为6000</td>
	<td><input class="formfield" type="text" name="max_gb_char" size="35" maxlength="200" value="<?php echo $config['max_gb_char'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b> 发表评论/留言间隔时间</b><br>游客发表评论/留言的最少间隔时间。为0时不限制。单位:秒</td>
	<td><input class="formfield" type="text" name="post_gb_time" size="35" maxlength="200" value="<?php echo $config['post_gb_time'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b> 最新日志/评论标题截取字符数</b><br>当您更换模板时，可能需要更改此项。</td>
	<td><input class="formfield" type="text" name="lastblog_cut_char" size="35" maxlength="200" value="<?php echo $config['lastblog_cut_char'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b> 搜索间隔时间</b><br>游客搜索时最少间隔时间。为0时不限制。单位:秒</td>
	<td><input class="formfield" type="text" name="search_time" size="35" maxlength="200" value="<?php echo $config['search_time'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>存放静态文件的目录名</b><br>默认为"archives",更改后程序会生成新文件夹</td>
	<td><input class="formfield" type="text" name="archive_folder" size="35" maxlength="200" value="<?php echo $config['archive_folder'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>日志时间格式</b><br>通过这里来改变日志的时间显示格式。<a href="http://cn.php.net/manual/zh/function.date.php" target="_blank">语法说明</a></td>
	<td><input class="formfield" type="text" name="date_format" size="35" maxlength="200" value="<?php echo $config['date_format'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>评论时间格式</b><br>通过这里来改变评论的时间显示格式。<a href="http://cn.php.net/manual/zh/function.date.php" target="_blank">语法说明</a></td>
	<td><input class="formfield" type="text" name="date_format_remark" size="35" maxlength="200" value="<?php echo $config['date_format_remark'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>留言时间格式</b><br>通过这里来改变留言的时间显示格式。<a href="http://cn.php.net/manual/zh/function.date.php" target="_blank">语法说明</a></td>
	<td><input class="formfield" type="text" name="date_format_gb" size="35" maxlength="200" value="<?php echo $config['date_format_gb'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>图片最大宽度</b><br>图片超过这个宽度后会被加上滚动条。单位:象素(px)</td>
	<td><input class="formfield" type="text" name="max_image_width" size="35" maxlength="200" value="<?php echo $config['max_image_width'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>超级日志管理员</b><br>只有这里的用户才可以管理全部日志。<br>其他用户只可以管理自己的日志。用户之间用逗号隔开</td>
	<td><input class="formfield" type="text" name="superadmin" size="35" maxlength="200" value="<?php echo $config['superadmin'];?>" ></td>
</tr>
<tr  class="listbg" nowrap>
	<td><b>私密表单密码</b><br>随意输入一个字符串，并不时更新。<br>此功能可以有效防spam！</td>
	<td><input class="formfield" type="text" name="private_code" size="35" maxlength="100" value="<?php echo $config['private_code'];?>" ></td>
</tr>

<tr  class="listbg">
	<td valign="top"><b>编辑器</b><br/>选择日志的编辑器</td>
	<td>
	<select name="editor">
		<option value="ubb_oblog" <?php if ($config['editor'] == "ubb_oblog") echo "selected";?> >ubb_oblog</option>
		<option value="html_fckeditor" <?php if ($config['editor'] == "html_fckeditor") echo "selected";?> >html_fckeditor</option>
		<option value="html_sina" <?php if ($config['editor'] == "html_sina") echo "selected";?> >html_sina</option>
	</select>
	</td>
</tr>

<tr  class="listbg">
	<td valign="top"><b>设定模版</b><br>选择您要使用的模板，更改后请重建一次静态页面</td>
	<td><select name="template"     >
	<?php
	if ($handle = @opendir('../templates'))  // list templates
	{
		while (false !== ($file = @readdir($handle)))
		{
			if(is_dir('../templates/'.$file) && $file != "." && $file != "..")
			{
				echo "<option value='$file' ";
				if ($file == trim($config['template'])) echo "selected ";
				echo " >$file</option>\n";
			}
		}
		@closedir($handle);
	}
	?>
	</select>
	</td></tr>
<tr  class="listbg">
	<td valign="top"><b>静态文件扩展名</b><br>如果您更改了此项，请重建一次静态页面</td>
	<td><select name="extraname" >
	<?php
	$arr = $extraname;
	foreach($arr as $ext)
	{
		echo "<option value='$ext' ";
		if ($ext == $config['extraname']) echo "selected";
		echo " >$ext</option>\n";
	}
	?>
	</select>
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>静态文件的存放方式</b><br>定义您的静态文件存放方式</td>
	<td><select name="keep_page_way" >
		<option value="day" <?php if ($config['keep_page_way'] == "day") echo "selected";?> >按日存放</option>
		<option value="month"  <?php if ($config['keep_page_way'] == "month") echo "selected";?> >按月存放</option>
		<option value="year"  <?php if ($config['keep_page_way'] == "year") echo "selected";?> >按年存放</option>
		<option value="all"  <?php if ($config['keep_page_way'] == "all") echo "selected";?> >放到一个文件夹 </option>
	</select>
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>服务器所在时区</b><br>Blog所在的服务器是放在地球的哪个时区<br />服务器现在的时间是: <?php echo obdate("Y-m-d H:i",time()) ?></td>
	<td><select name="servertimezone"     >
	<?php
	$arr = fetch_timezone();
	foreach($arr as $key=>$val)
	{
		echo "<option value='$key' ";
		if ($key == $config['servertimezone']) echo "selected";
		echo " >$val</option>\n";
	}
	?>
	</select>
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>访客所在时区</b><br>这个Blog主要面向哪个时区的用户</td>
	<td><select name="clienttimezone"     >
	<?php
	foreach($arr as $key=>$val)
	{
		echo "<option value='$key' ";
		if ($key == $config['clienttimezone']) echo "selected";
		echo " >$val</option>\n";
	}
	?>
	</select>
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>是否开启评论审核</b><br>开启后评论需要在后台审核之后才能显示</td>
	<td>
	<input type=checkbox name='checkremark' value='1' <?php if ($config['checkremark']) echo 'checked';?> class='checkbox' />	
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>是否生成静态页</b><br>开启后生成每篇日志的HTML页面</td>
	<td><input type=checkbox name="makehtml" value='1' <?php if ($config['makehtml']) echo 'checked';?>  class='checkbox' />
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>是否显示全文</b><br>开启后在日志列表里显示日志全文</td>
	<td><input type=checkbox name="fullarticle" value='1' <?php if ($config['fullarticle']) echo 'checked';?>  class='checkbox' />
</td></tr>
<!--tr  class="listbg">
	<td valign="top"><b>登陆时是否使用验证码</b><br>只有在服务器支持GD时才可以开启</td>
	<td><input type=checkbox  name="verify_code"  value='1' <?php if ($config['verify_code']) echo ' checked '; if ($disable) echo "disabled";?> class='checkbox' />
</td></tr-->
<tr  class="listbg">
	<td valign="top"><b>是否显示阅读次数</b><br />AJAX方式调用，不影响首页加载速度</td>
	<td><input type=checkbox name="show_viewcount"  value='1' <?php if ($config['show_viewcount']) echo 'checked';?>  class='checkbox' />
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>是否启用trackback</b><br/>有时trackback会带来很多spam</td>
	<td><input type=checkbox name="allow_trackback"  value='1' <?php if ($config['allow_trackback']) echo 'checked';?>  class='checkbox' />
</td></tr>
<tr  class="listbg">
	<td valign="top"><b>是否逆向排序评论</b><br/>后发表的评论排在上面</td>
	<td><input type=checkbox name="desc_remark"  value='1' <?php if ($config['desc_remark']) echo 'checked';?>  class='checkbox' />
</td></tr>

<tr  class="listbg">
	<td valign="top"><b>关闭 Blog</b><br>可以暂时关闭您的 Blog</td>
	<td><input type=checkbox name="close_blog" value='1' <?php if ($config['close_blog']) echo 'checked';?>  class='checkbox' />
</td></tr>

<tr  class="listbg" nowrap>
	<td valign="top"><b>关闭原因</b><br>填写您关闭Blog原因，仅当Blog被关闭时才有效。</td>
	<td><textarea class="formfield" type="text" name="close_reason" cols="50" rows="7" ><?php echo $config['close_reason'];?></textarea></td>
</tr>

<tr>
<td colspan="2" align="center">
 <input class="button" accesskey="y" type="submit" name="submit" value="提交" >
 <input class="button" accesskey="r" type="reset" name="" value="重置" >
</td></tr>
</form>
</table></td>
</tr>
</table>