Skip to content
This repository has been archived by the owner. It is now read-only.

Commit

Permalink
Cleaning House
Browse files Browse the repository at this point in the history
fixed rogue closing div. commenting out unused color options.
updating sticky footer so it doesn't throw errors in dashboard.
Some of josh changes.
  • Loading branch information
andrewmbacon committed Aug 12, 2014
1 parent 8712564 commit 02f8de1
Show file tree
Hide file tree
Showing 11 changed files with 99 additions and 103 deletions.
4 changes: 2 additions & 2 deletions footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @package cornerstone
*/
?>
</div><!-- #page -->

</div><!-- .container-->
</div><!-- #content -->
<div id="footers">
Expand Down Expand Up @@ -71,7 +71,7 @@
</ul>
</div>
</footer>
</div>
</div><!-- #footers -->
</div><!-- #page -->

<?php wp_footer(); ?>
Expand Down
109 changes: 47 additions & 62 deletions header.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
*
*/

$secondary = get_option( 'parentSiteTitle','');
$secondarylink = get_option( 'parentSiteLink','');
$headingColor = get_theme_mod( 'headingColor');
$parentColor = get_theme_mod( 'parentColor');
//$secondary = get_option( 'parentSiteTitle','');
//$secondarylink = get_option( 'parentSiteLink','');
//$headingColor = get_theme_mod( 'headingColor');
//$parentColor = get_theme_mod( 'parentColor');

//$nav1 = get_theme_mod( 'navoption1','textnav');
//$nav2 = get_theme_mod( 'navoption2','with-drop');
Expand All @@ -24,30 +24,20 @@
<html <?php language_attributes(); ?>>
<!--<![endif]-->




<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title><?php wp_title( '|', true, 'right' ); ?></title>
<title>
<?php wp_title( '|', true, 'right' ); ?>
</title>
<link rel="profile" href="http://gmpg.org/xfn/11">
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">

<?php wp_head(); ?>


</head>

<body <?php body_class(); ?> >

<nav id="skiplinks">
<a href="#site-navigation">Skip to Navigation</a>
<a href="#uc-search">Skip to UConn Search</a>
<a href="#content">Skip to Content</a>

</nav>
<nav id="skiplinks"> <a href="#site-navigation">Skip to Navigation</a> <a href="#uc-search">Skip to UConn Search</a> <a href="#content">Skip to Content</a> </nav>
<?php if(function_exists('uconn_banner_hook')){uconn_banner_hook();}?>
<div id="page" class="hfeed site">
<?php
Expand All @@ -61,24 +51,26 @@
<div class="col-sm-8">
<div class="site-branding" id="uc-site-header">
<?php
if(strlen($secondary) > 0 && strlen($secondarylink) > 0){
if(substr($secondarylink,0,4) != 'http'){
$secondarylink = 'http://'.$secondarylink;
if(strlen($secondary) > 0 && strlen($secondarylink) > 0){
if(substr($secondarylink,0,4) != 'http'){
$secondarylink = 'http://'.$secondarylink;
}
echo '<p id="uc-site-parent" class="'.$parentColor.'"><a href="'.$secondarylink.'">'.$secondary.'</a></p>';
}
echo '<p id="uc-site-parent" class="'.$parentColor.'"><a href="'.$secondarylink.'">'.$secondary.'</a></p>';
}
?>
<h1 id="uc-site-title" class="<?php echo $headingColor; ?>"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
?>
<h1 id="uc-site-title" class="<?php echo $headingColor; ?>"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home">
<?php bloginfo( 'name' ); ?>
</a></h1>
</div>
</div>
<div class="col-sm-4 <?php
if(strlen($secondary) > 0 && strlen($secondarylink) > 0){
if(substr($secondarylink,0,4) != 'http'){
$secondarylink = 'http://'.$secondarylink;
if(strlen($secondary) > 0 && strlen($secondarylink) > 0){
if(substr($secondarylink,0,4) != 'http'){
$secondarylink = 'http://'.$secondarylink;
}
echo 'parent-spacing';
}
echo 'parent-spacing';
}
?>">
?>">
<?php get_search_form(); ?>
</div>
</div>
Expand All @@ -87,47 +79,40 @@
<div id="nav-wrapper">
<div class="container">
<nav id="site-navigation" class="navbar navbar-default" role="navigation">

<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#primary-nav">
<span class="sr-only">Toggle navigation</span>
<span class="menu-icon">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</span>
<span class="menu-label">Menu</span>
</button>
<a class="navbar-brand visible-xs" href="<?php echo esc_url( home_url( '/' ) ); ?>"><?php bloginfo( 'name' ); ?></a>
</div>
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#primary-nav"> <span class="sr-only">Toggle navigation</span> <span class="menu-icon"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </span> <span class="menu-label">Menu</span> </button>
<a class="navbar-brand visible-xs" href="<?php echo esc_url( home_url( '/' ) ); ?>">
<?php bloginfo( 'name' ); ?>
</a> </div>
<a class="skip-link screen-reader-text sr-only" href="#content">
<?php _e( 'Skip to content', 'cs' ); ?></a>
<?php _e( 'Skip to content', 'cs' ); ?>
</a>
<div class="collapse navbar-collapse" id="primary-nav">
<?php
wp_nav_menu(
array(
'menu' => 'primary', /* menu name */
'menu_class' => 'nav navbar-nav'.$nav1.' '.$nav2,
'theme_location' => 'primary', /* where in the theme it's assigned */
'container' => false, /* container class */
'fallback_cb' => 'hale_main_nav_fallback',
'items_wrap' => '<ul id="%1$s" class="%2$s"><li><a href="'.home_url().'">Home</a></li>%3$s</ul>',
'walker' => new Bootstrap_Nav_Walker()/*,
'with_search' => true*/
)
);
?>
wp_nav_menu(
array(
'menu' => 'primary', /* menu name */
'menu_class' => 'nav navbar-nav'.$nav1.' '.$nav2,
'theme_location' => 'primary', /* where in the theme it's assigned */
'container' => false, /* container class */
'fallback_cb' => 'hale_main_nav_fallback',
'items_wrap' => '<ul id="%1$s" class="%2$s"><li><a href="'.home_url().'">Home</a></li>%3$s</ul>',
'walker' => new Bootstrap_Nav_Walker()/*,
'with_search' => true*/
)
);
?>
<div class="visible-xs-block">
<div class="navbar-form navbar-right">
<?php get_search_form(); ?>
</div>
<div class="navbar-form navbar-right">
<?php get_search_form(); ?>
</div>
</div>
</div>
</nav>
<!-- #site-navigation -->
<!-- #site-navigation -->
</div>
</div>
</header>
<!-- #masthead -->
<!-- #masthead -->
<div id="content" class="site-content">
<div class="container">
Empty file modified inc/custom-header.php
100755 → 100644
Empty file.
Empty file modified inc/extras.php
100755 → 100644
Empty file.
2 changes: 1 addition & 1 deletion inc/reg-sidebars.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ function custom_searchform($form){
}
$search_counter++;

$form = '<div class="searchform"><form action="'.home_url( '/' ).'" method="get" class="form-inline" role="form"><div class="form-group"><fieldset>';
$form = '<div class="searchform"><form action="'.home_url( '/' ).'" method="get" class="form-inline" role="form"><div class="form-group"><fieldset><legend class="sr-only">Search this Site</legend>';
$form .= '<label for="searchfield-'.$search_counter.'" class="sr-only">Search in '.home_url( '/' ).'></label>';
$form .= '<input type="text" name="s" id="searchfield-'.$search_counter.'" value="'.get_search_query().'" class="form-control search" placeholder="Search '.get_bloginfo("name").'... " />';
$form .= '<button type="submit" class="btn btn-default" title="Search"><i class="glyphicon glyphicon-search"></i><span class="sr-only">Search</span></button>';
Expand Down
Empty file modified inc/template-tags.php
100755 → 100644
Empty file.
18 changes: 14 additions & 4 deletions js/admin-style.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
jQuery(document).ready(function($) {
$('#accordion-section-layout_builder .ui-slider-handle').each(function(){
$(this).addClass('button button-primary');
});
jQuery(document).ready(function($) {
$('#accordion-section-layout_builder .ui-slider-handle').each(function(){
$(this).addClass('button button-primary');
});

var path = window.location.pathname;
if( path.split('/').indexOf('widgets.php') != -1 ){
$('.widgets-holder-wrap.sidebar-sidebar').each(function(i){
if( !($(this['children'][0]).is(":visible")) ){
$(this).css('display', 'none');
}
});
}

});
21 changes: 12 additions & 9 deletions js/cs.js
Original file line number Diff line number Diff line change
Expand Up @@ -215,16 +215,19 @@ jQuery(document).ready(function($) {

function stickyFoot(){
/* Andrew's Sticky Footer JS. */
var wrapperH = document.getElementById('page').clientHeight;
var footerH = document.getElementById('footers').clientHeight

var comboH = wrapperH + footerH;
var windowH = window.innerHeight;
if(windowH>=comboH){
$('body').addClass('sticky')
} else {
$('body').removeClass('sticky')

if (document.getElementById('page')!=null && document.getElementById('footers') !=null){
var wrapperH = document.getElementById('page').clientHeight;
var footerH = document.getElementById('footers').clientHeight
var windowH = window.innerHeight;
if(windowH>=wrapperH){
$('body').addClass('sticky')
} else {
$('body').removeClass('sticky')
}
}


}
window.onload = function (){
placeholderSupport = ("placeholder" in document.createElement("input"));
Expand Down
1 change: 1 addition & 0 deletions js/min/admin-style.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion js/min/cs.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

45 changes: 21 additions & 24 deletions page-home.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,32 +9,29 @@
$rows = get_theme_mod('homepagerows');
$count = 1;
get_header(); ?>

<div id="page-home">
<?php while ( have_posts() ) : the_post(); ?>

<?php for($i=0; $i<$rows; $i++){ /* Begin Homepage Builder... */?>
<div class="row">

<?php
$widths = get_theme_mod('homepage_'.$i);
$widths = explode(',',$widths);
foreach($widths as $width){
if($width == 0) break;
?>
<div class="col-sm-<?php echo $width; ?>">
<div class="home-section" id="home-section-<?php echo $count; ?>">
<?php if ( is_active_sidebar( 'home'.$count ) ) { ?>
<?php dynamic_sidebar( 'home'.$count ); ?>
<?php } else { ?>

<?php }; ?>
</div>
</div>
<?php $count ++; } ?>

</div><!-- /row-->
<?php } /* ... end Homepage Builder */?>

<?php for($i=0; $i<$rows; $i++){ /* Begin Homepage Builder... */?>
<div class="row">
<?php
$widths = get_theme_mod('homepage_'.$i);
$widths = explode(',',$widths);
foreach($widths as $width){
if($width == 0) break;
?>
<div class="col-sm-<?php echo $width; ?>">
<div class="home-section" id="home-section-<?php echo $count; ?>">
<?php if ( is_active_sidebar( 'home'.$count ) ) { ?>
<?php dynamic_sidebar( 'home'.$count ); ?>
<?php } else { ?>
<?php }; ?>
</div>
</div>
<?php $count ++; } ?>
</div>
<!-- /row-->
<?php } /* ... end Homepage Builder */?>
<?php endwhile; // end of the loop. ?>
</div>
<?php get_footer(); ?>

0 comments on commit 02f8de1

Please sign in to comment.