很多做网站的人在做门户资讯网站的时候
下面我们来一步一步修改!
首先在index
<div class="header_top">
<div class="wcenter">
<span class="time" id="time">
<table border="" align="center" >
<tr><td>
<div id="_userlogin">
<div class="userlogin">
<form name="userlogin" action="{dede:globalcfg_memberurl/}/index_do php" method="POST">
<input type="hidden" name="fmdo" value="login" />
<input type="hidden" name="dopost" value="login" />
<input type="hidden" name="keeptime" value="" />
<div class="fb">用户名:<input type="text" name="userid" size="" class="ipt txt" />
密码:<input type="password" name="pwd" size="" class="ipt txt" />
验证码:<input type="text" name="vdcode" size="" class="ipt txt" />
<img align="center" src="{dede:globalcfg_cmsurl/}/include/vdimgck php" /> <button type="submit" class="btn
">登录</button>
<a href="{dede:globalcfg_memberurl/}/index_do php?fmdo=user& dopost=regnew">注册帐号</a> <a href="{dede:global cfg_memberurl/}/resetpassword php">忘记密码?</a>
</form>
</div>
</div>
<!/userlogin >
<script language="javascript" type="text/javascript">CheckLogin();</script>
</td></tr></table></span>
<div class="toplinks"><a href=""onclick="thisstyle behavior= url(#default#homepage) ; this setHomePage( {dede:global cfg_basehost/} );">设为首页</a> | <a href="javascript:window external AddFavorite( {dede:global cfg_basehost/} {dede:global cfg_webname /} )">加入收藏</a> | <a href="{dede:global cfg_cmsurl/}/data/sitemap html" target="_blank">网站导航</a> | <a href="联系我们</a></div>
</div>
</div>
HTML代码现在我们已经有了
/*head */
header{
width:%;
width:px;
margin:auto;
overflow:hidden;
}
header_top{
height:px!important;
height:px;
lineheight: px;
color:#;
overflow:hidden;
background:url(/images/top_bg gif) repeat x;
}
center{
margin:px auto;
}
w {
width:px;
/*position:relative;*/
}
header_top time{
float:left;
paddingleft: px;
}
header_top toplinks{
float:right;
textalign:right;
}
header_top toplinks a{
margin:px;
}
header top{
clear:both;
overflow:hidden;
margintop: px;
}
header title{
float:left;
}
header title h a{
width:px;
height:px;
display:block;
overflow:hidden;
}
header banner{
width:px;
height:px;
float:right;
marginleft: px;
overflow:hidden;
}
ipt txt{
width:px;
border:px #CFCFCF solid;
}
fb{
color:#;
}
btn {
background: url("/images/comm bt gif") no repeat scroll transparent;
border: medium none;
color: #;
cursor: pointer;
height:px;
letterspacing: px;
lineheight: px;
overflow: hidden;
width:px;
}
HTML代码和CSS都有了
<script language="javascript" type="text/javascript" src="{dede:globalcfg_cmsurl/}/include/dedeajax js"></script>
<script language="javascript" type="text/javascript">
<!
$(function(){
$("a[_for]")mouseover(function(){
$(this)parents() children("a[_for]") removeClass("thisclass") parents() children("dd") hide();
$(this)addClass("thisclass") blur();
$("#"+$(this)attr("_for")) show();
});
$("a[_for=uc_member]")mouseover();
$("a[_for=flink_]") mouseover();
});
function CheckLogin(){
var taget_obj = documentgetElementById( _userlogin );
myajax = new DedeAjax(taget_objfalse false );
myajaxSendGet ("{dede:global cfg_cmspath/}/member/ajax_loginsta php");
DedeXHTTP = null;
}
>
</script>
现在都全了
下在是CSS中出现的图片
下载地址