Skip to content

Commit

Permalink
Merge pull request #122 from dasrecht/feature/wpsvbtle-102
Browse files Browse the repository at this point in the history
Adding Menu functionality to Theme
  • Loading branch information
Ricardo Rauch committed Dec 30, 2012
2 parents 120f81d + 0e03500 commit 49b727b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 18 deletions.
2 changes: 1 addition & 1 deletion wp-content/themes/svbtle/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ function theme_admin_header_image() {
}

function register_custom_menu() {
register_nav_menu('custom_menu', __('Svbtle Menu'));
register_nav_menu( 'primary', __( 'Svbtle Menu') );
}

require_once ( get_stylesheet_directory() . '/theme-options.php' );
Expand Down
18 changes: 1 addition & 17 deletions wp-content/themes/svbtle/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,25 +60,9 @@
<?php bloginfo( 'description' ); ?>
</h2>
</li>


<?php
$mypages = get_pages( );

foreach( $mypages as $page ) {
$content = $page->post_content;
if ( ! $content ) // Check for empty page
continue;

$content = apply_filters( 'the_content', $content );
?>
<li class="link">
<a href="<?php echo get_page_link( $page->ID ); ?>"><?php echo $page->post_title; ?></a>
</li>

<?php
}
?>
<?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_class' => 'nav-menu' ) ); ?>

<?php if (!empty($options['twitter_username'])): ?>
<li class="link twitter">
Expand Down

0 comments on commit 49b727b

Please sign in to comment.