-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
custom post type staff without styling, menu walker set up
- Loading branch information
Evan McEldowney
authored and
Evan McEldowney
committed
Jun 22, 2017
1 parent
569c23e
commit 7e50593
Showing
11 changed files
with
304 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
<?php | ||
/** | ||
* The template for displaying staff pages | ||
* | ||
* | ||
* @link https://codex.wordpress.org/Template_Hierarchy | ||
* | ||
* @package FoundationPress | ||
* @since FoundationPress 1.0.0 | ||
*/ | ||
|
||
get_header(); ?> | ||
|
||
<div class="main-wrap" role="main"> | ||
<article class="main-content"> | ||
<?php if ( have_posts() ) : ?> | ||
|
||
<?php /* Start the Loop */ ?> | ||
<?php while ( have_posts() ) : the_post(); ?> | ||
<?php get_template_part( 'template-parts/staff', get_post_format() ); ?> | ||
<?php endwhile; ?> | ||
|
||
<?php else : ?> | ||
<?php get_template_part( 'template-parts/staff', 'none' ); ?> | ||
|
||
<?php endif; // End have_posts() check. ?> | ||
|
||
<?php /* Display navigation to next/previous pages when applicable */ ?> | ||
<?php | ||
if ( function_exists( 'foundationpress_pagination' ) ) : | ||
foundationpress_pagination(); | ||
elseif ( is_paged() ) : | ||
?> | ||
<nav id="post-nav"> | ||
<div class="post-previous"><?php next_posts_link( __( '← Older posts', 'foundationpress' ) ); ?></div> | ||
<div class="post-next"><?php previous_posts_link( __( 'Newer posts →', 'foundationpress' ) ); ?></div> | ||
</nav> | ||
<?php endif; ?> | ||
|
||
</article> | ||
<?php get_sidebar(); ?> | ||
|
||
</div> | ||
|
||
<?php get_footer(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?php | ||
/** | ||
* Customize the output of menus for Foundation Program bar | ||
* | ||
* @package FoundationPress | ||
* @since FoundationPress 1.0.0 | ||
*/ | ||
|
||
/** | ||
* Big thanks to Brett Mason (https://github.com/brettsmason) for the awesome walker | ||
*/ | ||
|
||
if ( ! class_exists( 'Foundationpress_Program_Bar_Walker' ) ) : | ||
class Foundationpress_Program_Bar_Walker extends Walker_Nav_Menu { | ||
function start_lvl( &$output, $depth = 0, $args = array() ) { | ||
$indent = str_repeat("\t", $depth); | ||
$output .= "\n$indent<ul class=\"dropdown menu vertical\" data-toggle>\n"; | ||
} | ||
} | ||
endif; |
Oops, something went wrong.