Je veux convertir un site html......... en wordpress(localhost)...
mais j'ai rencontré un probléme avec le menu...
le menu apparait sans aucun style
**************html******
<div class="container">
<div class="col-md-2 col-sm-3 col-xs-12">
<a href="<?php echo get_home_url(); ?>">
<figure class="logo wow bounceInLeft animated">
<img src="<?php echo get_template_directory_uri();?>/images/logo.png">
</figure><!--logo-->
</a>
</div><!--col-md-2 col-sm-3 col-xs-12-->
<nav class="navbar navbar-default navbar-static-top">
<div class="">
<ul class="nav navbar-nav sf-menu" data-type="navbar">
<li class="is-act">
<a href="">Home</a>
</li>
<li>
<a href="">el2</a>
</li>
<li class="dropdown">
<a href="#">el3</a>
<ul class="dropdown-menu">
<li><a href="">el4</a></li>
<li><a href="">el5</a></li>
<li><a href="">el6</a></li>
</ul>
</li>
<li>
<a href="">el7</a>
</li>
<li>
<a href="">el8</a>
</li>
<li>
<a href="">el9</a>
</li>
<li>
<a href="">el10</a>
</li>
</ul>
</div>
</nav><!--navbar navbar-default navbar-static-top-->
</div> <!--stuck_container-->
</div><!--col-md-10 col-sm-3 col-xs-12-->
<div class="clear"></div><!--clear-->
</div><!--container-->
******WP*************
<?php
$args=array(
'theme_location' => 'primary',
'depth' =>2,
'container' =>'div',
'menu_class' =>'nav navbar-nav sf-menu'
);
wp_nav_menu($args);
?>
Modifié par zidex (22 Jan 2018 - 13:55)
mais j'ai rencontré un probléme avec le menu...
le menu apparait sans aucun style
**************html******
<div class="container">
<div class="col-md-2 col-sm-3 col-xs-12">
<a href="<?php echo get_home_url(); ?>">
<figure class="logo wow bounceInLeft animated">
<img src="<?php echo get_template_directory_uri();?>/images/logo.png">
</figure><!--logo-->
</a>
</div><!--col-md-2 col-sm-3 col-xs-12-->
<nav class="navbar navbar-default navbar-static-top">
<div class="">
<ul class="nav navbar-nav sf-menu" data-type="navbar">
<li class="is-act">
<a href="">Home</a>
</li>
<li>
<a href="">el2</a>
</li>
<li class="dropdown">
<a href="#">el3</a>
<ul class="dropdown-menu">
<li><a href="">el4</a></li>
<li><a href="">el5</a></li>
<li><a href="">el6</a></li>
</ul>
</li>
<li>
<a href="">el7</a>
</li>
<li>
<a href="">el8</a>
</li>
<li>
<a href="">el9</a>
</li>
<li>
<a href="">el10</a>
</li>
</ul>
</div>
</nav><!--navbar navbar-default navbar-static-top-->
</div> <!--stuck_container-->
</div><!--col-md-10 col-sm-3 col-xs-12-->
<div class="clear"></div><!--clear-->
</div><!--container-->
******WP*************
<?php
$args=array(
'theme_location' => 'primary',
'depth' =>2,
'container' =>'div',
'menu_class' =>'nav navbar-nav sf-menu'
);
wp_nav_menu($args);
?>
Modifié par zidex (22 Jan 2018 - 13:55)