修改路径 inc/user/user-profile.php
问候语:
<script type="text/javascript">today=new Date();var day; var date; var hello;hour=new Date().getHours();if(hour < 6){ hello=' 凌晨好! ';}else if(hour < 9){ hello=' 早上好!';}else if(hour < 12){ hello=' 上午好!';}else if(hour < 14){ hello=' 中午好! ';}else if(hour < 17){ hello=' 下午好! ';}else if(hour < 19){ hello=' 傍晚好!';}else if(hour < 22){ hello=' 晚上好! ';}else{ hello='夜深了! ';}function GetCookie(sName) { var arr = document.cookie.match(new RegExp("(^| )"+sName+"=([^;]*)(;|$)")); if(arr !=null){return unescape(arr[2])}; return null;}var Guest_Name = decodeURIComponent(GetCookie('author'));var webUrl = webUrl;if (Guest_Name != "null" ){ hello = Guest_Name+' , '+hello+' 欢迎回来。';}document.write(' '+hello);</script>
日期:
<script language="Javascript" type="text/javascript">
<!--
var enabled = 0; today = new Date();
var day; var date;
if(today.getDay()==0) day = " 星期日"
if(today.getDay()==1) day = " 星期一"
if(today.getDay()==2) day = " 星期二"
if(today.getDay()==3) day = " 星期三"
if(today.getDay()==4) day = " 星期四"
if(today.getDay()==5) day = " 星期五"
if(today.getDay()==6) day = " 星期六"
date = (today.getFullYear()) + "年" + (today.getMonth() + 1 ) + "月" + today.getDate() + "日" + day +"";
document.write(date);
// -->
</script>
插入路径:
在此路径之前
效果图: