1

当我尝试在 Firefox 中的 div 上使用 position: absolute 时,它​​似乎不起作用。对于我用于 div 的 jquery 日历position:absolute,它似乎适用于 linux 和 windows 中的所有浏览器,除了 windows 中的 mozilla。当我删除 position:absolute 时,它​​将在 windows firefox 中工作,但在所有其他浏览器中仅显示备用月份(一月、三月、五月、..)

 <div class="body">
    <div class="inner">
        <div class="container a pickable month" style="z-index: 999; left: 0px; visibility: visible;
            opacity: 1; display: block;">
            <div class="row a odd">
                <div class="first">
                    Su</div>
                <div>
                    Mo</div>
                <div>
                    Tu</div>
                <div>
                    We</div>
                <div>
                    Th</div>
                <div>
                    Fr</div>
                <div class="last">
                    Sa</div>
            </div>
            <div class="row b even">
                <div class="outside first">
                    28</div>
                <div class="outside">
                    29</div>
                <div class="outside">
                    30</div>
                <div>
                    1</div>
                <div>
                    2</div>
                <div>
                    3</div>
                <div class="last">
                    4</div>
            </div>
            <div class="row c odd">
                <div class="first">
                    5</div>
                <div>
                    6</div>
                <div>
                    7</div>
                <div>
                    8</div>
                <div>
                    9</div>
                <div>
                    10</div>
                <div class="last">
                    11</div>
            </div>
            <div class="row d even">
                <div class="first">
                    12</div>
                <div>
                    13</div>
                <div>
                    14</div>
                <div>
                    15</div>
                <div>
                    16</div>
                <div>
                    17</div>
                <div class="last">
                    18</div>
            </div>
            <div class="row e odd">
                <div class="first">
                    19</div>
                <div>
                    20</div>
                <div>
                    21</div>
                <div>
                    22</div>
                <div>
                    23</div>
                <div>
                    24</div>
                <div class="last">
                    25</div>
            </div>
            <div class="row f even">
                <div class="first">
                    26</div>
                <div>
                    27</div>
                <div>
                    28</div>
                <div>
                    29</div>
                <div>
                    30</div>
                <div>
                    31</div>
                <div class="outside last">
                    1</div>
            </div>
            <div class="row g odd">
                <div class="outside first">
                    2</div>
                <div class="outside">
                    3</div>
                <div class="outside">
                    4</div>
                <div class="outside">
                    5</div>
                <div class="outside">
                    6</div>
                <div class="outside">
                    7</div>
                <div class="outside last">
                    8</div>
            </div>
        </div>
        <div class="container b pickable month" style="z-index: 998; visibility: visible;
            opacity: 1; display: block; left: -200px;">
            <div class="row a odd">
                <div class="first">
                    Su</div>
                <div>
                    Mo</div>
                <div>
                    Tu</div>
                <div>
                    We</div>
                <div>
                    Th</div>
                <div>
                    Fr</div>
                <div class="last">
                    Sa</div>
            </div>
            <div class="row b even">
                <div class="outside first">
                    31</div>
                <div>
                    1</div>
                <div>
                    2</div>
                <div>
                    3</div>
                <div>
                    4</div>
                <div>
                    5</div>
                <div class="last">
                    6</div>
            </div>
            <div class="row c odd">
                <div class="first">
                    7</div>
                <div>
                    8</div>
                <div>
                    9</div>
                <div>
                    10</div>
                <div>
                    11</div>
                <div>
                    12</div>
                <div class="last">
                    13</div>
            </div>
            <div class="row d even">
                <div class="first">
                    14</div>
                <div>
                    15</div>
                <div>
                    16</div>
                <div>
                    17</div>
                <div>
                    18</div>
                <div>
                    19</div>
                <div class="last">
                    20</div>
            </div>
            <div class="row e odd">
                <div class="first">
                    21</div>
                <div>
                    22</div>
                <div>
                    23</div>
                <div>
                    24</div>
                <div>
                    25</div>
                <div>
                    26</div>
                <div class="last">
                    27</div>
            </div>
            <div class="row f even">
                <div class="first">
                    28</div>
                <div>
                    29</div>
                <div>
                    30</div>
                <div class="outside">
                    1</div>
                <div class="outside">
                    2</div>
                <div class="outside">
                    3</div>
                <div class="outside last">
                    4</div>
            </div>
            <div class="row g odd">
                <div class="outside first">
                    5</div>
                <div class="outside">
                    6</div>
                <div class="outside">
                    7</div>
                <div class="outside">
                    8</div>
                <div class="outside">
                    9</div>
                <div class="outside">
                    10</div>
                <div class="outside last">
                    11</div>
            </div>
        </div>
    </div>
</div>

样式表是http://snagglefoot.net/ainc/calendar-eightysix-default.css

4

1 回答 1

0

如果您没有在原始代码中指定,请尝试为有问题的 div 指定 width 或 top 或 left 属性。

职位在这里被注释掉。也许你不是故意的。

.calendar-eightysix .body {
        position: relative;
    }
        .calendar-eightysix .body .inner .container {
            /*position: absolute;*/
            left: 0;
        }
于 2013-01-18T08:06:16.127 回答