Html 底部的页脚
这是我的问题,我的页脚不会停留在页面底部 我尝试任何东西:清楚:两个;底部:0;边缘什么也没用 我的问题是:我怎样才能把它放在页面的底部 这是我的密码Html 底部的页脚,html,css,position,footer,Html,Css,Position,Footer,这是我的问题,我的页脚不会停留在页面底部 我尝试任何东西:清楚:两个;底部:0;边缘什么也没用 我的问题是:我怎样才能把它放在页面的底部 这是我的密码 <div id = "wrapper"> ..... .... <div id = "content2"> <div id = "fastMenu"> <a href="conseil-d-administration">
<div id = "wrapper">
.....
....
<div id = "content2">
<div id = "fastMenu">
<a href="conseil-d-administration">
<img src="<?php echo 'http://dev201.viglob.gtvr.com/client_file/themes /default/interface/FR/menuAdmin.png'; ?>" border="0" />
</a>
<a href="congres-2012">
<img src="<?php echo 'http://dev201.viglob.gtvr.com/client_file/themes/default/interface/FR/menuCongres.png'; ?>" border="0" />
</a>
<a href="formation">
<img src="<?php echo 'http://dev201.viglob.gtvr.com/client_file/themes/default/interface/FR/menuFormation.png'; ?>" border="0" />
</a>
<a href="devenir-membre">
<img src="<?php echo 'http://dev201.viglob.gtvr.com/client_file/themes/default/interface/FR/menuMembre.png'; ?>" border="0" />
</a>
</div>
<div id="contenu" class="txt">
</div> <?php //CONTENU2 ?>
<div id = "leftSide">
<?php include_once(INC_PATH_FULL_THEME.'event-teaser.php'); ?>
</div>
</div> <?php //CONTENT2 ?>
<div id = "footer">
</div>
如果您希望页脚始终位于页面底部,除非被内容压下,请签出。下面的代码应该是您所需要的全部代码 HTML:
<div class="wrapper">
<div class="header">
</div>
<div class="push"></div>
</div>
<div class="footer">
</div>
* {
margin: 0;
}
html, body {
height: 100%;
}
.wrapper {
min-height: 100%;
height: auto !important;
height: 100%;
margin: 0 auto -142px; /* the bottom margin is the negative value of the footer's height */
}
.footer, .push {
height: 142px; /* .push must be the same height as .footer */
}
/*
Sticky Footer by Ryan Fait
http://ryanfait.com/
*/
如果您希望页脚始终位于页面底部,除非被内容压下,请签出。下面的代码应该是您所需要的全部代码 HTML:
<div class="wrapper">
<div class="header">
</div>
<div class="push"></div>
</div>
<div class="footer">
</div>
* {
margin: 0;
}
html, body {
height: 100%;
}
.wrapper {
min-height: 100%;
height: auto !important;
height: 100%;
margin: 0 auto -142px; /* the bottom margin is the negative value of the footer's height */
}
.footer, .push {
height: 142px; /* .push must be the same height as .footer */
}
/*
Sticky Footer by Ryan Fait
http://ryanfait.com/
*/
将“位置:绝对;”放在页脚css中。
jsiddle将“位置:绝对;”放在页脚css中。
jsFIDLE您必须将以下内容添加到css中:
position: relative;
到包含页脚的元素
当然还有位置:页脚元素的绝对
就你而言:
#wrapper {
position: relative;
}
您必须在css中添加以下内容:
position: relative;
到包含页脚的元素
当然还有位置:页脚元素的绝对
就你而言:
#wrapper {
position: relative;
}
这对我有用。尝试使其适应您的代码。如果有帮助,请签名作为回答
html, body {
margin:0 auto; /* to center page align (can be left, right)*/
height:100%;
}
#container { /* contains everything, footer inclusive. */
min-height:100%;
position:relative;
}
#footer {
clear: both;
position:absolute;
bottom:0;
height:55px; /*Required, Height of the footer */
}
这对我有用。尝试使其适应您的代码。如果有帮助,请签名作为回答
html, body {
margin:0 auto; /* to center page align (can be left, right)*/
height:100%;
}
#container { /* contains everything, footer inclusive. */
min-height:100%;
position:relative;
}
#footer {
clear: both;
position:absolute;
bottom:0;
height:55px; /*Required, Height of the footer */
}
请参阅此
当我在jsfiddle
上格式化代码时,遇到了一些问题并解决了这些问题:-
在HTML上,缺少关闭div
在CSS上,从类“#contenu2”
(现在是“#contenu”
)中删除了数字2
新增位置:绝对代码>到#页脚
类
HTML:
请参阅此
当我在jsfiddle
上格式化代码时,遇到了一些问题并解决了这些问题:-
在HTML上,缺少关闭div
在CSS上,从类“#contenu2”
(现在是“#contenu”
)中删除了数字2
新增位置:绝对代码>到#页脚
类
HTML:
您希望页脚停留在屏幕底部还是内容底部<代码>位置:固定;底部:0代码>会将页脚推到屏幕底部,但其他内容不会影响页脚的显示position@potench我想把它放在底部:0;:DDo您希望页脚停留在屏幕底部还是内容底部<代码>位置:固定;底部:0代码>会将页脚推到屏幕底部,但其他内容不会影响页脚的显示position@potench我想把它放在底部:0;:“位置亲戚”怎么能烧掉你所有的东西?位置亲戚怎么能烧掉你所有的东西?