Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/74.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/36.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 如何让这个div停留在页面的末尾(而不是窗口的底部)?_Html_Css_Responsive Design - Fatal编程技术网

Html 如何让这个div停留在页面的末尾(而不是窗口的底部)?

Html 如何让这个div停留在页面的末尾(而不是窗口的底部)?,html,css,responsive-design,Html,Css,Responsive Design,在这个页面()上,当页面宽度1000px时保持在原来的位置 CSS 尝试将id=“end”移动到class=“story”之外,然后尝试将此css用于id=“end” 您的媒体查询正在缩小您的内容。。。将其从CSS中删除 @media handheld, screen and (max-width: 1000px){ .header { max-height: 600px; } } 在CSS中可用的是媒体规则 @media only screen

在这个页面()上,当页面宽度<900px时,页脚会跳到页面顶部,我希望它在宽度>1000px时保持在原来的位置

CSS

尝试将id=“end”移动到class=“story”之外,然后尝试将此css用于id=“end”


您的媒体查询正在缩小您的内容。。。将其从CSS中删除

@media handheld, screen and (max-width: 1000px){
    .header {
        max-height: 600px;
     }
}

在CSS中可用的是媒体规则

    @media only screen 
    and (min-width : 900px) {
    div.#footer {
    /* style for top of page Note: div is to add more specificity Greater than 1000px is next */
    }
}
    #footer {
    /* style for width is > 1000px */
    font-size: .8em;
    letter-spacing: .128em;
    font-family: "brandon-grotesque",Helvetica,sans-serif;
    font-weight: 600;
    text-transform: uppercase ;
    padding-top: 20px;
    padding-bottom: 20px;
    color: #272732;
    background-color: white;
    height: auto;
    bottom: 0px;  
    }

除此之外的任何内容都需要javascript。

您可以尝试添加此css属性“clear:All”吗?我想它会解决这个问题。900到1000之间的宽度呢?我假设宽度小于900,大于900?
@media handheld, screen and (max-width: 1000px){
    .header {
        max-height: 600px;
     }
}
    @media only screen 
    and (min-width : 900px) {
    div.#footer {
    /* style for top of page Note: div is to add more specificity Greater than 1000px is next */
    }
}
    #footer {
    /* style for width is > 1000px */
    font-size: .8em;
    letter-spacing: .128em;
    font-family: "brandon-grotesque",Helvetica,sans-serif;
    font-weight: 600;
    text-transform: uppercase ;
    padding-top: 20px;
    padding-bottom: 20px;
    color: #272732;
    background-color: white;
    height: auto;
    bottom: 0px;  
    }