HTML链接无法在Firefox中运行,但在Chrome和Safari中运行良好

时间:2013-12-10 09:39:02

标签: html css html5 firefox

启用链接的DIV的某些孩子在Firefox中不起作用,尽管它们在Chrome中运行良好。

请参阅www.tekiki.com的实际示例。尝试单击列出的第一个应用程序的文本区域。它不会起作用。但是,即使文本和图标都属于同一个父链接,也可以单击该图标。

我们尝试了StackOverflow的其他建议,包括设置overflow:hidden和清除浮动,但似乎都没有。

我们正在测试Firefox 24。

帮助?

HTML:

<a class="app_box click_drop" href="/itunes-store/apps/free-apps/app/runtastic-road-bike-pro-gps-cycling-computer-tracker?itunes-store-id=468429333" itunes_id="468429333" path="/36/6013/468429333">
            <div class="icon_box">
                <div class="icon" style="background-image: url(&quot;http://a3.mzstatic.com/us/r30/Purple/v4/4b/91/03/4b910379-2983-22be-358c-0c894ca82216/mzl.izwihsdx.256x256-75.jpg&quot;);"></div>
            </div>      
            <div class="caption_box">
                <div class="details_box">
                    <div class="name">Runtastic Road Bike PRO GPS Cycling Computer &amp; Tracker</div>                  
                    <div class="desc_box">
                        <div class="desc text">“Free today with ‘App of the Day’. 

Download ‘App of the Day’, and every day discover one paid app absolutely free!”

4.5+ Rating, TechCrunch, Mashable, NYTimes and others are raving about Runtastic... Find out why &amp; download...</div>
                    </div>                  
                    <div class="ratings_box">
                        <div class="avg_rating" style="background-position: 0px -91px;"></div> <span class="num_ratings">2040</span>                            
                    </div>                  
                    <div class="price_box" style="display: block;">                     
                        <span class="cur_price">Free</span> <span class="old_price">$4.99</span> <span style="display:none" class="sponsored">Sponsored</span>
                    </div>                  
                </div>
            </div>
        </a>

CSS:

.page_list .app_box:first-child {
    margin-top: 0;
}
.page_list .list a {
    color: #5C5C5C;
}
.page_list .app_box {
    -moz-box-sizing: border-box;
    background: url("/images/dandy/caption_bg.png") repeat scroll 0 0 rgba(0, 0, 0, 0);
    border-radius: 5px 5px 5px 5px;
    box-shadow: 0 0 5px #CCCCCC;
    display: block;
    margin: 25px 0 0;
    overflow: hidden;
}
a {
    color: #5E87B0;
    text-decoration: none;
}

3 个答案:

答案 0 :(得分:1)

有一个z-index问题导致无法将其链接。

z-index: -1上使用#bg_graphics即可。

对于实例,

#bg_graphics {
    background: url("/images/web/bg_graphics.png") repeat scroll 0 0 rgba(0, 0, 0, 0);
    height: 465px;
    left: 50%;
    margin-left: -900px;
    position: fixed;
    width: 1800px;
    z-index: -1;
}

答案 1 :(得分:0)

尝试将z-index应用于更高级别,它可以正常工作。

#page_box {
    -moz-box-sizing: border-box;
    margin: 50px auto;
    position: relative;
    z-index: 9999;
}

答案 2 :(得分:0)

试试这个

z-index: -1;添加到#bg_graphics

z-index: 9999;添加到#page_box