1.guestbook.php(留言程序) <html> <head> <script language="javaScript"> <!-- <!-- var hellotext="为了您的最佳浏览效果请您使用IE4.0以上的版本和800*600分辨率" var thetext="" var started=false var step=0 var times=1
function welcometext() { times-- if (times==0) { if (started==false) { started = true; window.status = hellotext; setTimeout("anim()",1); } thetext = hellotext; } }
function showstatustext(txt) { thetext = txt; setTimeout("welcometext()",4000) times++ }
function anim() { step++ if (step==7) {step=1} if (step==1) {window.status='>==='+thetext+'===<'} if (step==2) {window.status='=>=='+thetext+'==<='} if (step==3) {window.status='>=>='+thetext+'=<=<'} if (step==4) {window.status='=>=>'+thetext+'<=<='} if (step==5) {window.status='==>='+thetext+'=<=='} if (step==6) {window.status='===>'+thetext+'<==='} setTimeout("anim()",200); } // --> welcometext();
function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } //--> </script> <title>天地网络留言版</title> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> </head> <style type="text/CSS"> <!-- a:link { font-size: 9pt; color: #FFFFFF} --> </style> <body> <? $PAGESIZE=5; $db=MySQL_connect("localhost","root",""); mysql_select_db("lyanban",$db); $result=mysql_query("SELECT * FROM message order by date desc",$db); $rowcount=mysql_num_rows($result); $PAGES=CEIL($rowcount/$PAGESIZE); if($rowcount==0) {echo "目前没有留言!<a href=guestbook.htm>欢迎您留言!</a>";}