wordpress
wp_nav_menu( array(
'theme_location' => 'menu-2',
'menu_id' => 'small-header-menu',
'menu_class' => 'small-menu'
) );
.small-menu li:last-child a{ border-right: none; }
-----------------------------------------------------------
add_action('wp_enqueue_scripts' , 'zm_add_fa_css');
function zm_add_fa_css(){
wp_enqueue_style('custom-fa' , 'https://use.fontawesome.com/releases/v5.0.9/css/all.css' ) ;
}
https://use.fontawesome.com/releases/v5.0.9/css/all.css
.small-menu{
padding: 0px;
height: 50px;
color: #fff;
}
.small-menu li{
display: inline-block;
}
.small-menu li a{
padding: 0 20px;
border-right: 1px solid #fff;
height: 100%;
line-height: 50px;
display: inline-block;
color: #fff;
}
.small-menu li:last-child a{
border-right: none;
}
wordpress loop custom post type
$args = array( 'post_type' => 'services', 'posts_per_page' => 4 );
$loop = new WP_Query( $args );
while ( $loop->have_posts() ) : $loop->the_post();
the_title();
echo '<div class="entry-content">';
the_content();
echo '</div>';
endwhile;
Comments
Post a Comment