背景图象css歌剧问题

时间:2010-06-02 08:43:16

标签: css opera

我在歌剧中有问题。我有一个关于应用backgorund图像的ullin liga的系列文章。当我将鼠标悬停在链接上时,指针光标不会显示。

这是一个知道错误,代码如下

  • / cricket“title =”Cricket“id =”cricket-link“style =”background-image:url(/wp-content/themes/blank2L/images/sidebar-cricket-bg.jpg) ;“onmouseover =”$()。hoverSidebarImage('/ wp-content / themes / blank2L / images / sidebar-cricket-bghover.jpg','cricket'); return false;“onmouseout =”$()。originalSidebarImage('/ wp-content / themes / blank2L / images / sidebar-cricket-bg.jpg','cricket'); return false;“> Cricket
  • #sidebar ul {
    margin: 0;
    padding: 0 0 27px 16px;
    display: block;
    float: left;
    width: 180px;
    }
    
    #sidebar ul li {
    background-image: url(images/left-nav-bg.jpg);
    background-repeat: no-repeat;
    margin: 0;
    margin-bottom: 10px;
    padding: 0;
    display: block;
    float: left;
    width: 180px;
    height: 40px;
    list-style-type: none;
    cursor:pointer !important;
    }
    
    
    #sidebar ul li a {
    background-repeat: no-repeat;
    background-position: 2px 2px;
    margin: 0;
    padding: 8px 8px 0 4px;
    display: block;
    float: left;
    width: 168px;
    height: 32px;
    color: #ffffff;
    font-family: Helvetica, Arial, sans-serif;
    font-size: 18px;
    font-weight: bold;
    text-align: right;
    cursor:pointer !important;
    } 
    

    2 个答案:

    答案 0 :(得分:0)

    你应该使用悬停阶段来获得这个id

    #sidebar ul li hover{
    background-repeat: no-repeat;
    background-position: 2px 2px;
    margin: 0;
    display: block;
    float: left;
    width: 168px;
    height: 32px;
    color: #ffffff;
    font-family: Helvetica, Arial, sans-serif;
    font-size: 18px;
    font-weight: bold;
    text-align: right;
    cursor:pointer !important;
    }
    

    以你的风格添加这个css。

    答案 1 :(得分:0)

    问题已解决,将mouseover和mouseout事件更改为true;