我试图建立一个启动页面(静态页面),问题是当添加 div 时它们位于 bg-picture 下方.. 我该如何解决这个问题?我想要一个 600px 居中的 div 持有人,里面有内容。
我的代码,
<html><head>
    <meta charset="utf-8">
    <title>Splash Page</title>
    <style>
        img.splash {
            /* Set rules to fill background */
            min-height: 100%;
            min-width: 1024px;
            /* Set up proportionate scaling */
            width: 100%;
            height: auto;
            /* Set up positioning */
            position: fixed;
            top: 0;
            left: 0;
        }
        @media screen and (max-width: 1024px){
            img.splash {
                left: 50%;
                margin-left: -512px; }
        }
        .splashHold{ margin:0 auto; background-color:#0C3; width:600px; height:150px; z-index:100;}
    </style>
</head>
<body>
    <a href="ttp://planeta.se/luiza/exempelsida/"><img class="splash" src="<?php bloginfo('stylesheet_directory'); ?>/images/splashBg.jpg"></a>
    <div class="splashHold">Test writing here..</div>