拼网页前的准备工作

{
    margin
:  0px auto ;
    border-width
:  0px ;
}
/* ===power by dare21century@gmail.com==== */
body 
{
    font
:  12px "宋体" ;
    color
:  #555 ;
    width
:  970px ;
}
ul
{ list-style : none ;  margin : 0 ;  padding : 0px }
li
{ list-style : none ;  margin : 0 ;  padding : 0px }
img
{ border : none ; }
a:link 
{
    color
:  #333333 ;
    text-decoration
:  none ;
}
a:visited 
{
    text-decoration
:  none ;
    
}
a:hover 
{
    text-decoration
:  none ;
}
a:active 
{
    text-decoration
:  none ;
}
.clear
{
    clear
: both ;
    height
: 0 ;
    font-size
: 0 ;
    
}

 

 

     -moz-border-radius: 5px;
    -khtml-border-radius: 5px;
    -webkit-border-radius: 5px;
    border-radius: 5px;

 

待续...... 

 有一个js把me迷住了!  嘿嘿~~~

< script type = " text/javascript " >

<!--
        document.write(
" <noscript><iframe src=*.html></iframe></noscript> " );
        
function  fun()
        {
            
return   false ;
        }
        document.onselectstart
= fun;    
    
// -->

< / script>

 各行变色[来源小贺的博儿]

 

         protected   void  GridView1_RowDataBound( object  sender, GridViewRowEventArgs e)
        {
            
#region   变色
            
if  (e.Row.RowType  ==  DataControlRowType.DataRow)
            {
                
// 当鼠标移到行上时更改背景色 
                e.Row.Attributes.Add( " onmouseover " " c=this.style.backgroundColor;this.style.backgroundColor='#CED5F9' " );
                
// 当鼠标移开时还原背景色 
                e.Row.Attributes.Add( " onmouseout " " this.style.backgroundColor=c " );
            }
            
for  ( int  i  =   0 ; i  <  GridView1.Rows.Count; i ++ )
            {
                LinkButton lb 
=  GridView1.Rows[i].FindControl( " LinkButton1 " as  LinkButton;
                
if  (lb  !=   null )
                {
                    lb.Attributes.Add(
" onclick " " return confirm('您真的要删除此行吗?')  " );
                }
            }
            
#endregion
        }

 

 设为首页 加入收藏:

 

设置为首页的方法为:
< href =#  onClick ="this.style.behavior='url(#default#homepage)'; this.setHomePage('URL');event.returnValue=false;" > 设为首页 </ a >
URL就是你要设定的网址地址

要设置当前网页的地址为首页,你可以这样:
< href =#  onClick ="this.style.behavior='url(#default#homepage)'; this.setHomePage(document.location.href);event.returnValue=false;" > 设为首页 </ a >
上述方法采用javascript的document.location对象的href属性来获得当前网页的全路径。 
<a href="Javascript:window.external.addFavorite('http://netsos.cnblogs.com','小贺')">加入收藏</a>

 

 

 

你可能感兴趣的:(工作)