Css DIV-won';我不会出现在一个';下面是什么
我不知道如何让一个DIV出现在它下面的DIV上。换句话说,我的网页有一个头部,一个DIV向左浮动,一个DIV向右浮动。下面是一个菜单栏。我没有很多菜单项,所以我希望DIV中的图像向右浮动,以部分重叠菜单栏。我能让它在绝对定位下工作。。。但这并不理想。我继续改变了菜单栏的宽度,但这更多的是为了得到我想要的。想法 www.sacspartans.orgCss DIV-won';我不会出现在一个';下面是什么,css,wordpress,html,css-float,css-position,Css,Wordpress,Html,Css Float,Css Position,我不知道如何让一个DIV出现在它下面的DIV上。换句话说,我的网页有一个头部,一个DIV向左浮动,一个DIV向右浮动。下面是一个菜单栏。我没有很多菜单项,所以我希望DIV中的图像向右浮动,以部分重叠菜单栏。我能让它在绝对定位下工作。。。但这并不理想。我继续改变了菜单栏的宽度,但这更多的是为了得到我想要的。想法 www.sacspartans.org <div id="page" class="hfeed site"> <header id="masthead" class="s
<div id="page" class="hfeed site">
<header id="masthead" class="site-header" role="banner">
<div id="header-left">
<hgroup>
<h1 class="site-title">
<a href="<?php echo esc_url( home_url( '/' ) ); ?>">
<img src="http://sacspartans.org/wp-
content/uploads/2013/05/banner.png" alt="SacSpartans"
title="SacSpartans" border="0" />
</a>
</h1>
<h2 class="site-description"><?php bloginfo( 'description' ); ?>
</h2>
</hgroup>
</div>
<div id="header-right">
<img src="http://sacspartans.org/wp-
content/uploads/2013/05/california1.png" alt="MSU Alumni Club of
the Sacramento Valley" title="MSU Alumni Club of the Sacramento
Valley" border="0" />
</div>
<div id="navigation-bar">
<nav id="site-navigation" class="main-navigation" role="navigation">
<h3 class="menu-toggle"><?php _e( 'Menu', 'twentytwelve' ); ?></h3>
<a class="assistive-text" href="#content" title="<?php esc_attr_e(
'Skip to content', 'twentytwelve' ); ?>"><?php _e( 'Skip to
content', 'twentytwelve' ); ?></a>
<?php wp_nav_menu( array( 'theme_location' => 'primary',
'menu_class' => 'nav-menu' ) ); ?>
</nav>
</div>
查看Z-index。另外,使用相对位置。如果你在jsfiddle.net上创建一个示例,这会很有帮助,因为如果我们都在看和处理同一件事情,这会更容易。发布呈现的HTML,而不是PHP源代码。你能用小提琴或线框插图来解释吗?我不熟悉jsfiddle.net。或者如何发布呈现的HTML。看来我会坚持我的想法,因为我想不出来,哈哈。
/* Header */
#header-left {
float: left;
}
#header-right {
float: right;
margin-top: 0;
}
#navigation-bar {
width: 575px;
}