BottomNavigationActivity 出现顶部白色条框,底部遮挡内容--解决

我们在创建Project的时候,如果选用了BottomNavigationActivity 来创建activity,等你在fragment里布局得时候,你会发现顶部会出现白色条框,高度相当一个bar的高度。

白色条框解决:

activity_main.xml删除这句,它有一个actionBar的高度。

 android:paddingTop="?attr/actionBarSize">

顶部有问题,底部也有问题。

底部遮挡内容

activity_main.xml里fragment里,添加这句,66只是自己随意,最好设置一个Bottombar的高度。

    android:layout_marginBottom="66dp"
  • 10
    点赞
  • 13
    收藏
    觉得还不错? 一键收藏
  • 9
    评论
以下是一个简单的HTML5表单,包含所有要求的元素: ```html <!DOCTYPE html> <html> <head> <title>注册表单</title> <meta charset="utf-8"> </head> <body> <form> <label for="email">邮件地址:</label> <input type="text" id="email" name="email" required> @ <input type="text" id="email-domain" name="email-domain" required> . <input type="text" id="email-tld" name="email-tld" required> <br><br> <label for="password">密码:</label> <input type="password" id="password" name="password" required> <br><br> <label for="confirm-password">确认密码:</label> <input type="password" id="confirm-password" name="confirm-password" required> <br><br> <label for="phone">手机号码:</label> <input type="tel" id="phone" name="phone" pattern="[0-9]{11}" required> <br><br> <label for="captcha">验证码:</label> <input type="text" id="captcha" name="captcha" required> <img src="captcha.php" alt="验证码" onclick="this.src='captcha.php?'+Math.random()"> <button type="button" onclick="this.previousSibling.src='captcha.php?'+Math.random()">换一张</button> <br><br> <button type="button">免费获取验证码</button> <label for="sms-code">短信验证码:</label> <input type="text" id="sms-code" name="sms-code" required> <br><br> <label for="terms">同意服务条款:</label> <input type="checkbox" id="terms" name="terms" required> <br><br> <button type="submit">立即注册</button> </form> </body> </html> ``` 解释一下: 1. 邮件地址的三个部分分别是`email`、`email-domain`和`email-tld`,都是必填项。 2. 密码输入框使用`type="password"`。 3. 确认密码输入框与密码输入框相同。 4. 手机号码输入框使用`type="tel"`和`pattern="[0-9]{11}"`,表示必须是11位数字。 5. 验证码使用一个`img`标签显示图片,并在`onclick`事件中生成新的验证码图片。 6. 免费获取验证码使用一个普通的`button`标签。 7. 短信验证码输入框与其他输入框相同。 8. 同意服务条款使用一个`checkbox`标签,并添加`required`属性。 9. 立即注册使用一个普通的`button`标签,不是`type="submit"`,因为需要添加JavaScript代码来验证表单。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 9
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值