鼠标移上去,显示元素

利用css实现鼠标移上去,出现元素。

        .t2{
            background-color:yellow;
            float:left;
            width:200px;
        
        }
        .t2:hover{
            background-color:green;
        }
        .t2:hover .t3{
            display:block;
        }
        .t3{
            background-color:red;
            display:none;
        }
        p{
            margin:0;
            
        }

1

2222

你可能感兴趣的:(鼠标移上去,显示元素)