Bootstrap页脚不在底部

use*_*040 6 html javascript css twitter-bootstrap

我试图强制我的页脚在我的网站底部.滚动时我不希望它粘在一起,只是在向下滚动网页时出现在底部.

目前 - 网页显示页脚位于内容下方.我添加了这样的代码bottom:0;,发现它坚持并不适合我的网站.我还添加了html, body { height:100%;}在其他stackoverflow问题上查看的代码- 但没有任何乐趣.

任何意见,将不胜感激.

代码:

    .footer {
    	background: #F37A1D;
       	position : absolute;
    	width: 100%;
    	border-top: 3px solid #F37A1D;
    }
Run Code Online (Sandbox Code Playgroud)
    <div class="footer">
    <div class="container">
            <p>&copy; COMPAY 2015</p>
        </div>
    </div>
Run Code Online (Sandbox Code Playgroud)

Dmi*_*riy 6

*{
    padding: 0;
    margin: 0;
}

html {
  position: relative;
  min-height: 100%;
}
body {
  /* Margin bottom by footer height */
  margin-bottom: 60px;
}
.footer {
  position: absolute;
  bottom: 0;
  width: 100%;
  /* Set the fixed height of the footer here */
  height: 60px;
  background: #F37A1D;
 border-top: 3px solid #F37A1D;   
}
Run Code Online (Sandbox Code Playgroud)
<div class="footer">
    <div class="container">
            <p>&copy; COMPAY 2015</p>
        </div>
    </div>
Run Code Online (Sandbox Code Playgroud)