根据时间自动调整站点风格是不错的想法,这种根据时间自动调整站点风格也不是什么新鲜事,记得好久以前也见过类似的文章或方法,只不过当时没有特别注意。下面说一下它们的实现方法,目前网上有这样两种实现方法: 一、采用服务端的代码 ASP版本: elseif hour(now)response.write "day.css" else response.write "night.css" end if %> "/> PHP版本: 二、采用JavaScript代码 <BR><!– <BR>function getCSS(){ <BR>datetoday = new Date(); <BR>timenow=datetoday.getTime(); <BR>datetoday.setTime(timenow); <BR>thehour = datetoday.getHours(); <BR>if (thehour<12) <BR>display = "morning.css"; <BR>else if (thehour<17) <BR>display = "day.css"; <BR>else <BR>display = "night.css"; <BR>//(…想要更多再加即可…) <BR>var css = ‘<'; <BR>css+='link rel="stylesheet" href='+display+' \/'; <BR>css+='>'; <BR>document.write(css); <BR>} <BR>–> <BR>