本文主要为大家详细介绍了php实现在线通信录功能的具体代码,具有一定的参考价值,感兴趣的小伙伴们可以参考一下。希望对大家有所帮助。
本文实例为大家分享php在线通信录编写代码,供大家参考,具体内容如下
<?php
session_start();
define("n", true);
if(empty($_session["uid"])) {
header("location: ./login.html");
}
?>
<!doctype html>
<html>
<head>
<title>添加</title>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<link rel="stylesheet" href="css/index.css" />
<script type="text/javascript" src="js/calendar.js"></script>
</head>
<body>
<?php
require_once "header.php";
?>
<p id = "add">
<h2 class = "title">添加信息</h2>
<form method = "post" action = "add_do.php">
<table cellpadding = "0" cellspacing = "0">
<tr>
<td>姓名:</td>
<td><input type = "text" name = "username" /></td>
</tr>
<tr>
<td>性别:</td>
<td>
男<input type = "radio" name = "usersex" value = "1" checked = "checked" />
女<input type = "radio" name = "usersex" value = "0" />
</td>
</tr>
<tr>
<td>生日:</td>
<td><input type = "text" onclick="new calendar().show(this);" name = "userbirth" /></td>
</tr>
<tr>
<td>电话:</td>
<td><input type = "text" name = "usertel"></td>
</tr>
<tr>
<td>地址:</td>
<td><input type = "text" name = "useraddr"></td>
</tr>
<tr>
<td colspan = "2" style = "text-align:center;">
<input type = "submit" name = "sub" value = "提 交" />
</td>
</tr>
</table>
</form>
</p>
<?php
require_once "footer.php";
?>
</body>
</html>
相关推荐:
php简单实现socks5代理服务器
php封装搜索类实例
php学习mvc框架之路由
以上就是php实现在线通讯录的实例的详细内容。