Created
November 9, 2013 01:10
-
-
Save ShenXuGongZi/7380141 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php include 'header.php'; ?> | |
<script type="text/javascript" language="javascript"> | |
function ChangeTxt(obj){ | |
var val = obj.options[obj.selectedIndex].value; //获取下接框选择的值 | |
document.getElementById("menu").value=val; //将获取的值填写到文本框 | |
} | |
</script> | |
<form action="action.php?kind=<?php echo $_GET["kind"]?> | |
&come=addziliao" method="post"> | |
<div class="container"> | |
<div class="alert alert-warning"> <strong>注意:</strong> | |
每个项目单页只能添加10个目录。 | |
</div> | |
<div class="page-header"> | |
<h1> | |
<?php | |
if ("yjya"==$_GET["kind"]) { | |
echo "应急预案"; | |
}elseif ("fkyh"==$_GET["kind"]) { | |
echo "防控隐患"; | |
}elseif ("fxgl"==$_GET["kind"]) { | |
echo "风险管理"; | |
}elseif ("aqjy"==$_GET["kind"]) { | |
echo "安全教育"; | |
} | |
?></h1> | |
</div> | |
<p>标题</p> | |
<input type="text" class="form-control" name="title" placeholder="请输入资料标题"> | |
<br> | |
<p>内容</p> | |
<textarea id="elm1" name="content" class="xheditor" name="content" style="height:300px;width: 100%"></textarea> | |
<script type="text/javascript" language="javascript"> | |
$('#elm1').xheditor({upLinkUrl:"upload.php",upLinkExt:"zip,rar,txt",upImgUrl:"upload.php",upImgExt:"jpg,jpeg,gif,png",upFlashUrl:"upload.php",upFlashExt:"swf",upMediaUrl:"upload.php",upMediaExt:"avi",urlType:"abs"}); | |
</script> | |
<br/> | |
<br> | |
<div class="form-with"> | |
<select name="topid" name="title" class="form-control" onchange="ChangeTxt(this)"> | |
<?php | |
$conn=mysql_connect("localhost","root","host700"); | |
mysql_select_db("youtian"); | |
mysql_query("set names uft8"); | |
$result=mysql_query("SELECT * FROM title where kind='".$_GET["kind"]."'"); | |
while ($title=mysql_fetch_array($result)) { | |
?> | |
<option value="<?php echo($title["id"])?>"><?php echo($title["title"])?></option> | |
<?php | |
} | |
?> | |
</select> | |
</div> | |
<input type="text" name="title" id="menu" value=""> | |
<div class="navbar-right"> | |
<button type="button" class="btn btn-primary" onclick="location='ziliao.php?kind='"> | |
<span class="glyphicon glyphicon-list"></span> | |
返回列表 | |
</button> | |
| |
<button type="submit" class="btn btn-success"> | |
<span class="glyphicon glyphicon-send"></span> | |
提交数据 | |
</button> | |
</div> | |
</div> | |
</form> | |
<?php include 'footer.php'; ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment