douyi9597 2015-02-01 14:12
浏览 28

移动菜单后,为什么我的身体正好?

I am trying to make my own website based on WordPress and i found really nice theme (FANWOOD LIGHT BY DEVPRESS) but i need to move "Navigation" or Menu below the header. When i did it my body just moved to right and i dont know what happned.

There is the webpage on free webhosting: http://stbrezenecka.wz.cz/ (It's in Czech language)

There is my header.php:

<?php
/**
 * The Header for our theme.
 *
 * Displays all of the <head> section and everything up till <div id="main">
 *
 * @package Fanwood Light
 * @since Fanwood Light 1.0
 */
?><!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<meta name="viewport" content="width=device-width" />
<title><?php wp_title( '|', true, 'right' ); ?></title>
<link rel="profile" href="http://gmpg.org/xfn/11" />
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
<!--[if lt IE 9]>
<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
<![endif]-->

<?php wp_head(); ?>
</head>

<body <?php body_class(); ?>>
    <?php do_action( 'before' ); ?>
    <header id="masthead" class="site-header" role="banner">
        <hgroup>
        <?php
            $header_image = get_header_image();
            if ( ! empty( $header_image ) ) { ?>
                <a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
                    <img src="<?php echo esc_url( $header_image ); ?>" class="header-image" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" />
                </a>
            <?php } ?>
            <div class="header">
            <h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
            <h2 class="site-description"><?php bloginfo( 'description' ); ?></h2>
            </div>
        </hgroup>
    </header><!-- #masthead .site-header -->
    <div id="main-navigation">
        <nav id="site-navigation" class="navigation-main" role="navigation">
            <h1 class="menu-toggle"><?php _e( 'Menu', 'fanwood_light' ); ?></h1>
            <div class="assistive-text skip-link"><a href="#content" title="<?php esc_attr_e( 'Skip to content', 'fanwood_light' ); ?>"><?php _e( 'Skip to content', 'fanwood_light' ); ?></a></div>

            <?php wp_nav_menu( array( 'theme_location' => 'primary' ) ); ?>
        </nav><!-- .site-navigation .main-navigation -->
    </div>
<div id="page" class="hfeed site">
<div id="main" class="site-main">

Threre is screenshot: http://i.stack.imgur.com/CtAT8.png

</div>
  • 写回答

2条回答 默认 最新

  • doutun1875 2015-02-01 14:15
    关注

    You have <?php do_action( 'before' ); ?> which creates a <div>, so after </header> add </div>

    评论

报告相同问题?

悬赏问题

  • ¥15 基于卷积神经网络的声纹识别
  • ¥15 Python中的request,如何使用ssr节点,通过代理requests网页。本人在泰国,需要用大陆ip才能玩网页游戏,合法合规。
  • ¥100 为什么这个恒流源电路不能恒流?
  • ¥15 有偿求跨组件数据流路径图
  • ¥15 写一个方法checkPerson,入参实体类Person,出参布尔值
  • ¥15 我想咨询一下路面纹理三维点云数据处理的一些问题,上传的坐标文件里是怎么对无序点进行编号的,以及xy坐标在处理的时候是进行整体模型分片处理的吗
  • ¥15 CSAPPattacklab
  • ¥15 一直显示正在等待HID—ISP
  • ¥15 Python turtle 画图
  • ¥15 stm32开发clion时遇到的编译问题