<?php
/*
 * 注意：此文件由tpl_engine编译型模板引擎编译生成。
 * 如果您的模板要进行修改，请修改 templates/default/modules/group/group_creat.html
 * 如果您的模型要进行修改，请修改 models/modules/group/group_creat.php
 *
 * 修改完成之后需要您进入后台重新编译，才会重新生成。
 * 如果您开启了debug模式运行，那么您可以省去上面这一步，但是debug模式每次都会判断程序是否更新，debug模式只适合开发调试。
 * 如果您正式运行此程序时，请切换到service模式运行！
 * 
 * 如有您有问题请到官方论坛（http://tech.jooyea.com/bbs/）提问，谢谢您的支持。
 */
?><?php
	//引入公共模块
	require("foundation/module_group.php");
	
	//引入语言包
	$g_langpackage=new grouplp;
	
	//必须登录才能浏览该页面
	require("foundation/auser_mustlogin.php");
	
	//变量声明区
	$user_id=get_sess_userid();
	
	$dbo=new dbex;
	dbtarget('r',$dbServs);
	
	//数据表定义区
	$t_group_type=$tablePreStr."group_type";
	
	//缓存功能区
	require($webRoot.$baseLibsPath."model/group_type_list.model.cache.php");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title></title>
<script language="JavaScript">
parent.guide("group");
function check_form(){
	if(document.getElementById("group_name").value==""||
		document.getElementById("group_resume").value==""||
		document.getElementById("group_tag").value==""||
		document.getElementById("group_type").value==""||
		document.getElementById("group_logo").value==""){
		parent.Dialog.alert("<?php echo $g_langpackage->g_no_pass;?>");return false;
	}
	if(document.getElementById("group_resume").value.length>=90){
		parent.Dialog.alert("<?php echo $g_langpackage->g_resume_len;?>");
		return false;
	}
}

</script>
<link rel="stylesheet" type="text/css" href="skin/<?php echo $skinUrl;?>/css/row_menus.css">
<link rel="stylesheet" type="text/css" href="skin/<?php echo $skinUrl;?>/css/iframe.css">
</head>
<body>
  <div class="main_right_title">
     <span class="main_title_dot8"></span>
     <span class="main_title_txt"><?php echo $g_langpackage->g_group;?></span>
  </div>
  	<div id="tabsB">
		<ul>
			<li><a href="#" class="nowbutl"><span class="nowbutr"><?php echo $g_langpackage->g_creat;?></span></a></li>
		</ul>
		<div class="div_but_2" onclick="location.href='?app=group'"><?php echo $g_langpackage->g_return;?></div>
	</div>
	<table class='main main_left'>	
		
		<form action='do.php?act=group_creat' method='post' enctype="multipart/form-data" onsubmit='return check_form()'>
			<input type="hidden" name="group_type_name" id="group_type_name" />
		
		<tr height="30"><th height="30"><?php echo $g_langpackage->g_name;?>:</th>
			<td><input type='text' name='group_name' id='group_name' autocomplete='off' maxlength="40" /></td>
		</tr>
		
		<tr height="30"><th><?php echo $g_langpackage->g_intro;?>:</th>
			<td><textarea rows='6' cols='25' name='group_resume' id='group_resume'></textarea></td>
		</tr>
		
		<tr height="30"><th><?php echo $g_langpackage->g_join_type;?>:</th>
			<td>
				<select name='group_join_type'>
					<option value='0'><?php echo $g_langpackage->g_freedom_join;?></option>
					<option value='1'><?php echo $g_langpackage->g_check_join;?></option>
					<option value='2'><?php echo $g_langpackage->g_refuse_join;?></option>
				</select>
			</td>
		</tr>
		
		<tr height="30"><th><?php echo $g_langpackage->g_tag;?>:</th>
			<td><input type='text' name='group_tag' id='group_tag' autocomplete='off' maxlength="40" /></td>
		</tr>
		
		<tr height="30"><th><?php echo $g_langpackage->g_type;?>:</th>
    	<td>
        <?php echo $group_type;?>
			</td>
		</tr>
		
		<tr height="30">
			<th><?php echo $g_langpackage->g_logo;?>:</th>
			<td><input type='file' name='attach[]' id='group_logo' style='width:280px' /></td>
		</tr>
		
		<tr>
			<td></td>
			<td><input type='submit' id="UploadButton" value='<?php echo $g_langpackage->g_button_creat;?>' class="anniu"  name='action' /></td>
		</tr>
	</form>
</table>
</body>
</html>