问题遇到的现象和发生背景
小程序wxss显示底部居中如何控制
遇到的现象和发生背景,请写出第一个错误信息
图中按钮是固定在下方的,现在想要倒计时部分的view可以靠在按钮上方并且居中,现在代码如下
wxml:
<view class='content'>
<text style="display: block;text-align: center;font-size: 30px;">
倒计时:\n{{ticker}}
</text>
</view>
<button class='btn' bindtap='tapChange'>点击</button>
wxss
.content{
font-family: 微软雅黑;
color: white;
bottom:47px;
padding:0px;
margin:0px;
position:absolute;
text-align: center;
}
.btn{
width:100%;
border-radius: 3px;
padding-top:2px;
font-size:14px;
background-color:#CC3333;
color:white;
overflow:hidden;
height:45px;
bottom: 0;
position: fixed;
}