HTML / CSS 如何在屏幕底部写文字?

How to write text on the bottom of the screen in HTML / CSS?

我想在屏幕底部放置一行文本,但重要的是不要覆盖页面的其他元素。我尝试了 <footer> 标签,但不幸的是它覆盖了内容。我在阅读另一个问题时发现的代码:

footer{
    position: normal;
    bottom: 0;
    width:100%;
    left:0;
}

所以我正在寻找的是一行文本,如果页面比显示器的高度 "longer" 或停留在屏幕底部(如页脚一样)如果页面的高度小于或等于显示器的高度。

尝试 position: absolute; 您可能需要使用 flexbox 技术重新考虑您的布局。查看 https://css-tricks.com/snippets/css/a-guide-to-flexbox/