欢迎光临
我们一直在努力

PHP+DBM的同学录程序(5)-PHP教程,PHP应用

建站超值云服务器,限时71元/月

10、会员信息显示文件show.php3

<?

if($login){

require("common.php3");

if(!isset($id))error("怎么没有填写用户的id?");

else{

$id=chop($id);

$dbm=dbmopen("class","r");

if(!dbmexists($dbm,$id))error("没有这个用户id!");

else{

$data=dbmfetch($dbm,$id);

$info=explode("|!:!|",$data);

$name=$info[0]; $nickname=$info[1]; $mail=$info[2]; $home=$info[3]; $oicq=$info[4];

$icq=$info[5]; $add=$info[6]; $tel=$info[7]; $birth=$info[8]; $job=$info[9];

$intro=$info[10]; $sex=$info[11];

}

dbmclose($dbm);

}

?>

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">

<html><head><title>查 看 <?echo$name?> 的 资 料</title>

<meta content="text/html; charset=gb2312" http-equiv=content-type>

<style type=text/css>a {

color: #336699; font-family: "宋体"; font-size: 9pt; text-decoration: none

}

a:hover {

color: #ff0000; font-family: "宋体"; font-size: 9pt; text-decoration: underline

}

body {

font-family: "宋体", "serif"; font-size: 9pt

}

td {

font-family: "宋体", "serif"; font-size: 9pt

}

input {

font-size: 9pt

}

p {

font-size: 9pt

}

br {

font-size: 9pt

}

tr {

font-size: 9pt

}

table {

font-size: 9pt

}

input {

font-family: arial,宋体; font-size: 9pt; padding-top: 3px

}

input.text {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

input.file {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

select {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

textarea {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

.stedit {

border-bottom: #000066 1px solid; border-left: #4a3163 1px solid; border-right: #4a3163 1px solid; border-top: #4a3163 1px solid; font-size: 9pt

}

.stbtm {

border-bottom: #665b8e 1px solid; border-left: #ffffff 1px solid; border-right: #665b8e 1px solid; border-top: #ffffff 1px solid; color: #000000; font-size: 9pt; height: 20px

}

.ddd {

color: #ffffff; filter: glow(color=black,strength=1); font-size: 9pt; line-height: 13pt; position: relative; width: 100%

}

</style></head><body bgcolor=#333366>

<div align=center><table bgcolor=#000000 border=0 cellpadding=8 cellspacing=1 height=312

width="80%"><center>

<tr>

<td align=middle bgcolor=#b2b2b2 colspan=2 height=6>

<p align=center><?echo$name?>的详细资料 </p>

</td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=6 width="34%">姓??名</td>

<td align=left bgcolor=#dedfdf height=6 width="66%"><?echo$name?> </td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12

width="34%">nickname</td>

<td align=middle bgcolor=#dedfdf height=12 width="66%">

<p align=left><?echo$nickname?></p>

</td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">性??别</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$sex?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">邮件地址</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$mail?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">个人主页</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><a href=<?echo$home?>><?echo$home?></a></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">目前职业</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$job?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=14 width="34%">oicq号码</td>

<td align=left bgcolor=#dedfdf height=14 width="66%">

<?

if($oicq=="")echo "不告诉你!";

else{

?>

<a href="http://search.tencent.com/cgi-bin/friend/user_show_info?ln=<?echo$oicq?>" target=_blank title=<?echo$name?>的oicq号码是<?echo$oicq?>,点击查看资料><img border=0 height=16 src="http://infocenter.tencent.com/<?echo$oicq?>/l/00/0/" width=16> <?echo$oicq?></a>

<?

}

?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">icq 号码</td>

<td align=left bgcolor=#dedfdf height=12 width="66%">

<?

if($oicq=="")echo "不告诉你!";

else{

?><img src=http://wwp.icq.com/scripts/online.dll?icq=<?echo$icq;?>&img=7><?echo$icq?>

<?

}?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">生日日期</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$birth?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">联系地址</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$add?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">联系电话</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$tel?></td>

</tr>

<tr>

<td align=middle bgcolor=#dedfdf height=12 width="34%">个人简介</td>

<td align=left bgcolor=#dedfdf height=12 width="66%"><?echo$intro?></td>

</tr>

</center>

</table>

</div></body></html>

<?

}else header("location:login.php3");

?>

11、css文件:

a {text-decoration: none; color: #336699; font-family: "宋体"; font-size: 9pt}

a:hover {text-decoration: underline; color: #ff0000; font-family: "宋体"; font-size: 9pt}

body { font-family: "宋体", "serif"; font-size: 9pt}

td { font-family: "宋体", "serif"; font-size: 9pt}

input { font-size: 9pt}

p { font-size: 9pt}

br { font-size: 9pt}

tr { font-size: 9pt}

table { font-size: 9pt}

input { font-family: arial,宋体; font-size: 9pt; padding-top: 3px }

input.text {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

input.file {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

select {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

textarea {

background-color: #f0f0f0; border-bottom: #101010 1px solid; border-left: #101010 1px solid; border-right: #101010 1px solid; border-top: #101010 1px solid; color: #000000

}

.stedit { font-size: 9pt; border-left: 1px solid #4a3163;

border-right: 1px solid #4a3163; border-top: 1px solid #4a3163;

border-bottom: 1px solid #000066 }

.stbtm { background-color: #cococo; color: #000000; font-size: 9pt; height: 20px;

border-left: 1px solid #ffffff; border-right: 1px solid #665b8e;

border-top: 1px solid #ffffff; border-bottom: 1px solid #665b8e }

好了,完了

赞(0)
版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com 特别注意:本站所有转载文章言论不代表本站观点! 本站所提供的图片等素材,版权归原作者所有,如需使用,请与原作者联系。未经允许不得转载:IDC资讯中心 » PHP+DBM的同学录程序(5)-PHP教程,PHP应用
分享到: 更多 (0)

相关推荐

  • 暂无文章