Skip to content

Commit

Permalink
Revert f8f887d..a20dbe4
Browse files Browse the repository at this point in the history
This rolls back to commit f8f887d.
  • Loading branch information
andrewmbacon committed Apr 14, 2015
1 parent a20dbe4 commit 0732bac
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 21 deletions.
15 changes: 2 additions & 13 deletions header.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
*
*/
include 'inc/vars.php';
$top_nav_style = get_theme_mod('top_nav_style');
?>
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
Expand Down Expand Up @@ -38,7 +37,7 @@
<?php if(function_exists('uconn_banner_hook')){uconn_banner_hook();}?>
<div id="page" class="hfeed site">
<header id="masthead" class="site-header <?php if ($headerImg != ''){echo 'header-image';} ?>" role="banner">
<div id="site-title" class="<?php if ($top_nav_style != 'maxmegamenu'){echo 'hidden-xs'}; ?>">
<div id="site-title" class="hidden-xs">
<div class="container">
<?php include 'inc/header-img.php'; ?>
<div class="row">
Expand All @@ -55,17 +54,7 @@
</div>
<div id="nav-wrapper">
<div class="container">
<?php
if ($top_nav_style == 'maxmegamenu'){
// load maxmegamenu top nav
wp_nav_menu(array(
'theme_location' => 'primary'
));
} else {
// load bootstrap top nav
include 'inc/nav.php';
}
?>
<?php include 'inc/nav.php'; ?>
</div>
</div>
</header>
Expand Down
34 changes: 26 additions & 8 deletions inc/customizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,27 +78,45 @@ function huskypress_parentSite_register( $wp_customize )

function huskypress_navoption_register( $wp_customize )
{
$wp_customize->add_setting( 'top_nav_style', //Give it a SERIALIZED name (so all theme settings can live under one db record)
$wp_customize->add_setting( 'navoption1', //Give it a SERIALIZED name (so all theme settings can live under one db record)
array(
'default' => 'bootstrap', //Default setting/value to save
'default' => 'textnav', //Default setting/value to save
'type' => 'theme_mod', //Is this an 'option' or a 'theme_mod'?
'capability' => 'edit_theme_options', //Optional. Special permissions for accessing this setting.
'transport' => 'refresh', //What triggers a refresh of the setting? 'refresh' or 'postMessage' (instant)?
)
);
$wp_customize->add_control('top_nav_style', array(
$wp_customize->add_control('navoption1', array(
'type' => 'select',
'label' => 'Top Navigation Style',
'label' => 'Navigation Option 1',
'section' => 'nav',
'choices' => array(
'bootstrap'=>'Bootstrap Dropdown Menu',
'maxmegamenu' => 'Mega Dropdown Menu'
'textnav'=>'Text',
'bar' => 'Bar',
'stack-top'=>'Tabs'
)
)
);
$wp_customize->add_setting( 'navoption2', //Give it a SERIALIZED name (so all theme settings can live under one db record)
array(
'default' => 'with-drop', //Default setting/value to save
'type' => 'theme_mod', //Is this an 'option' or a 'theme_mod'?
'capability' => 'edit_theme_options', //Optional. Special permissions for accessing this setting.
'transport' => 'refresh', //What triggers a refresh of the setting? 'refresh' or 'postMessage' (instant)?
)
);
$wp_customize->add_control('navoption2', array(
'type' => 'select',
'label' => 'Navigation Option 2',
'section' => 'nav',
'choices' => array(
'with-drop'=>'Dropdowns',
'with-left' => 'Left Nav'
)
)
);
}
add_action( 'customize_register', 'huskypress_navoption_register' );

add_action( 'customize_register', 'huskypress_navoption_register' );

function huskypress_layoutoption_register( $wp_customize )
{
Expand Down

0 comments on commit 0732bac

Please sign in to comment.