【问题标题】:Static message above the page in htmlhtml中页面上方的静态消息
【发布时间】:2010-01-29 05:39:25
【问题描述】:

我有一个内容很长的网页。我只想在浏览器窗口的底部放置一些消息,即使您向下滚动页面,该消息也应该始终可见。

你们能告诉我如何使用简单的 css、html、jquery 或 PHP 来实现吗

谢谢

【问题讨论】:

    标签: php javascript jquery html css


    【解决方案1】:

    我相信它会是:

    .status_bar {
        bottom: 0;
        position: fixed;
    }
    

    如果您需要它在 IE 6 中工作,那么我建议您查看this fix(我现在在一台无法访问 IE 6 的 Linux 机器上,所以我不能肯定地说——但我通常发现 Stu Nicholls 对隐藏的浏览器错误进行了正确的修复。)

    【讨论】:

      【解决方案2】:

      尝试使用粘性页脚。代码在http://ryanfait.com/sticky-footer/

      【讨论】:

        【解决方案3】:

        试试这个:

        <div style="position: fixed; bottom: 0; width: 500px">
            ... your content here ..
        </div> 
        

        注意:在 IE6 中不起作用

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 1970-01-01
          • 2016-10-19
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 2012-04-15
          • 1970-01-01
          • 1970-01-01
          相关资源
          最近更新 更多