【问题标题】:Bootstrap 3 panel height 100%Bootstrap 3 面板高度 100%
【发布时间】:2014-07-26 10:38:04
【问题描述】:

我已经尝试了一段时间,但无法使其正常工作。基本上,我需要引导面板(边框)占据 100% 的窗口。但似乎它只采用了固定高度而不是 100%。这是我的plunk

【问题讨论】:

标签: twitter-bootstrap twitter-bootstrap-3


【解决方案1】:

使用这个 jquery 函数,将类全高添加到面板。

$(window).resize(function() {
    $('.panel.full-height').each(function() {
        $(this).height($(window).height() - $(this).offset().top - 20);
    });
    $('#results').height($(window).height() - $('#results').offset().top - 106);
});
setTimeout(function() { $(window).resize(); },200);

【讨论】:

    猜你喜欢
    • 2013-08-29
    • 2014-05-31
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-02-06
    相关资源
    最近更新 更多