php實(shí)現(xiàn)在線通訊錄功能(附源碼)
本文實(shí)例為大家分享php在線通信錄編寫代碼,供大家參考,具體內(nèi)容如下
<?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";
?>
<div 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>
</div>
<?php
require_once "footer.php";
?>
</body>
</html>
源碼下載:在線通訊錄
以上就是本文的全部內(nèi)容,希望對大家學(xué)習(xí)php程序設(shè)計(jì)有所幫助。
相關(guān)文章
PHP怎么實(shí)現(xiàn)網(wǎng)站保存快捷方式方便用戶隨時(shí)瀏覽
網(wǎng)站保存快捷方式以后在瀏覽起來就比較方便了,實(shí)現(xiàn)的方法有很多,下面為大家詳細(xì)介紹下使用PHP實(shí)現(xiàn)網(wǎng)站快捷方式的保存,有此需求的朋友可以參考下,希望對大家有所幫助2013-08-08
php自定義函數(shù)br2nl實(shí)現(xiàn)將html中br換行符轉(zhuǎn)換為文本輸入中換行符的方法【與函數(shù)nl2br功能相反】
這篇文章主要介紹了php自定義函數(shù)br2nl實(shí)現(xiàn)將html中br換行符轉(zhuǎn)換為文本輸入中換行符的方法,具有與函數(shù)nl2br相反的功能,并附帶了相應(yīng)的JS實(shí)現(xiàn)方法,需要的朋友可以參考下2017-02-02
PHP使用PDO訪問oracle數(shù)據(jù)庫的步驟詳解
POD擴(kuò)展是在PHP5中加入,該擴(kuò)展提供PHP內(nèi)置類 PDO來對數(shù)據(jù)庫進(jìn)行訪問,不同數(shù)據(jù)庫使用相同的方法名,解決數(shù)據(jù)庫連接不統(tǒng)一的問題。下面這篇文章主要給大家介紹了關(guān)于PHP使用PDO訪問oracle數(shù)據(jù)庫的步驟,需要的朋友可以參考下。2017-09-09
PHP中數(shù)字檢測is_numeric與ctype_digit的區(qū)別介紹
PHP中的兩個(gè)函數(shù)is_numeric和ctype_digit都是檢測字符串是否是數(shù)字,但也存在一點(diǎn)區(qū)別2012-10-10
PHP has encountered an Access Violation at 7C94BD02解決方法
PHP has encountered an Access Violation at 7C94BD02解決方法2009-08-08
PHP+APACHE實(shí)現(xiàn)網(wǎng)址偽靜態(tài)
這篇文章主要介紹了PHP+APACHE通過使用mod rewrite模塊實(shí)現(xiàn)網(wǎng)址偽靜態(tài)的相關(guān)資料,需要的朋友可以參考下2015-02-02
PHP設(shè)計(jì)模式 注冊表模式(多個(gè)類的注冊)
注冊表模式其實(shí)是一個(gè)單例模式,注冊表類提供靜態(tài)方法(或單例對象的實(shí)例化方法)來讓其它對象訪問其中的數(shù)據(jù)(通常是對象)。整個(gè)系統(tǒng)中的每個(gè)對象都可以訪問這些數(shù)據(jù)對象2012-02-02

