为什么对 segmentfault 设置 margin-right 不生效

Viewed 1441

segmentfault 的页面,我想让他占满屏幕,用了各种方法,右边还是会空出一大块

    //document.getElementById("question-wrap").style.width="auto";
    document.getElementById("question-wrap").style.marginRight="5%";
    document.getElementById("question-wrap").style.marginLeft="auto";
    //document.getElementById("question-wrap").style.margin="5%";
    //document.getElementById("question-wrap").style.display="inline-block";

用的是油猴

image.png

2 Answers

试了一下,把这些 max-width 去掉就可以撑满了
image.png

因为右面本来是有一竖条广告的……可能是被你的广告拦截插件给弄没了,但是外层的 DOM 还占着空间。

P.S. 宽屏下这种纯文本的页面占满一屏真的是巨丑……谁家网站设计也不会这么设计的……