【问题标题】:Safari overlaps header logo with bodySafari 将标题徽标与正文重叠
【发布时间】:2014-05-06 01:28:43
【问题描述】:

我用的是淘主题http://themeforest.net/item/tao-retina-responsive-wordpress-portfolio-theme/5913809

我遇到问题的网站是http://www.thamon.co.uk/ 如果您使用 Safari 打开页面,它会将徽标与所有页面的正文重叠。

在styles.css中,我有他关注与我认为与问题有些相关的标题相关的代码

.header {
        position: relative; 
    }
        .header .header-primary-content { 
            display: table;
            width: 100%;
            position: relative; 
            padding: 10px 0;
            margin-bottom: 10px;

            border-bottom: 1px solid #e6e6e6; 
        } 
            /* Border shadow */
            .header .header-primary-content:after { 
                content: " ";
                position: relative;
                z-index: -1; 
                bottom: -2px;
                left: 0;
                width: 100%;
                height: 1px;

                background: rgba(255, 255, 255, .5);
            }
                .logo, .header-buttons {
                    display: table-cell;
                    vertical-align: middle;

                }

                /**
                 * Logo
                 */
                .logo {
                    width: 70%;
                }
                    .logo a {
                        display: inline-block;

                    position: relative;

                        width: 120px;
                        height: 40px;
                        margin-left: 410px;

                        vertical-align: middle

                        color: #444652;
                        text-shadow: 1px 1px #fff, 0px 0px #0E0E0E, 2px 3px 1px #E3E3E3;
                        font: normal 400 60px 'Merriweather', Georgia, "Times New Roman", Times, serif;
                    }
                        .no-touch .logo a:hover {
                            animation: tinywiggle 220ms ease-out;
                        }

【问题讨论】:

    标签: css wordpress safari


    【解决方案1】:

    当徽标的高度为 120 像素 x 147 像素时,您在 .logo a 上放置了 40 像素的高度。尝试将 .logo a 的高度与 img 匹配,或者从 .logo a 中删除高度

    【讨论】:

    • 感谢您的建议。但是,既不删除 height: 40px 命令,也不添加 height: 400px 的测试值,似乎并没有改变 safari 中的任何内容。
    • 尝试删除高度,我自己检查过,它在 safari 中修复。
    • 我的朋友,你能把你删除高度的代码的摘录发给我吗?我不知道为什么,但对我来说,删除这一行并不会改变任何事情。在你删除高度之前,你看到我在 safari 中所说的问题了吗?
    • logo a { display: inline-block;位置:相对;宽度:120px;左边距:410px;垂直对齐:中间颜色:#444652;文字阴影:1px 1px #fff,0px 0px #0E0E0E,2px 3px 1px #E3E3E3;字体:正常 400 60px 'Merriweather', Georgia, "Times New Roman", Times, serif; } .no-touch .logo a:hover { 动画:tinywiggle 220ms 缓出; }
    • 我刚刚检查过,我猜它现在工作正常吗?因为它似乎更新了高度,现在它在 Safari 中显示对我来说很好。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-10-01
    • 2013-11-08
    • 1970-01-01
    • 1970-01-01
    • 2020-07-16
    • 1970-01-01
    相关资源
    最近更新 更多