Permalink
Browse files

housekeeping, validating HTML, widget id generated by WP, moved some …

…code around for better semantic markup
  • Loading branch information...
1 parent fcf4dd1 commit 5cbee4e3817a20bd5e9b3c0fcff0098c4cc7e7b5 @wycks committed Dec 23, 2011
Showing with 62 additions and 57 deletions.
  1. +8 −10 footer.php
  2. +4 −0 functions.php
  3. +7 −5 header.php
  4. +8 −8 index.php
  5. +15 −13 loop.php
  6. +9 −8 menu.php
  7. +4 −4 sidebar.php
  8. +7 −9 stylesheets/base.css
View
18 footer.php
@@ -4,17 +4,15 @@
* @subpackage WP-Skeleton
*/
?>
-<div class="clear"></div>
- <div class="footer">
- <hr />
- <div class="sixteen columns">
-
+ <div class="clear"></div>
+ <div class="footer">
+ <hr />
+ <div class="sixteen columns">
<?php if ( is_active_sidebar( 'footer-sidebar' ) ) : ?> <?php dynamic_sidebar( 'footer-sidebar' ); ?>
- <?php else : ?><p>You need to drag a widget into your sidebar in the WordPress Admin</p>
- <?php endif; ?>
-
- </div>
- </div>
+ <?php else : ?><p>You need to drag a widget into your sidebar in the WordPress Admin</p>
+ <?php endif; ?>
+ </div>
+ </div>
</div>
<?php wp_footer(); ?>
View
4 functions.php
@@ -13,6 +13,8 @@
'name' => 'Right SideBar',
'id' => 'right-sidebar',
'description' => 'Widgets in this area will be shown on the right-hand side.',
+ 'before_widget' => '<div id="%1$s">',
+ 'after_widget' => '</div>',
'before_title' => '<h3>',
'after_title' => '</h3>'
));
@@ -22,6 +24,8 @@
'name' => 'Footer SideBar',
'id' => 'footer-sidebar',
'description' => 'Widgets in this area will be shown in the footer.',
+ 'before_widget' => '<div id="%1$s">',
+ 'after_widget' => '</div>',
'before_title' => '<h3>',
'after_title' => '</h3>'
));
View
12 header.php
@@ -4,16 +4,18 @@
* @subpackage WP-Skeleton
*/
?>
-
+<!DOCTYPE html>
+<html <?php language_attributes(); ?>>
+
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<!--[if lt IE 7 ]><html class="ie ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]><html class="ie ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]><html class="ie ie8" lang="en"> <![endif]-->
-<!--[if (gte IE 9)|!(IE)]><!--><html lang="en"> <!--<![endif]-->
-
+<!--[if gte IE 9 ]><html class="no-js ie9" lang="en"> <![endif]-->
+
<title><?php wp_title('|',true,'right'); ?><?php bloginfo('name'); ?></title>
<meta name="description" content="<?php bloginfo('description'); ?>" />
@@ -44,6 +46,6 @@
<body <?php body_class(); ?>><!-- the Body -->
-<div class="container">
+ <div class="container">
-<?php get_template_part( 'menu', 'index' ); // get the blog header( menu + logo/site title) ?>
+ <?php get_template_part( 'menu', 'index' ); // get the blog header( menu + logo/site title) ?>
View
16 index.php
@@ -3,14 +3,14 @@
* @package WordPress
* @subpackage WP-Skeleton
*/
-?><!DOCTYPE html>
-<html <?php language_attributes(); ?>>
-
- <?php get_header(); //the Header ?>
-
- <?php get_template_part( 'loop', 'index' ); //the Loop ?>
+
+ get_header(); //the Header
+
+ get_template_part( 'loop', 'index' ); //the Loop
- <?php get_template_part( 'sidebar', 'index' ); //the Sidebar ?>
+ get_template_part( 'sidebar', 'index' ); //the Sidebar
- <?php get_footer(); //the Footer ?>
+ get_footer(); //the Footer
+
+?>
View
28 loop.php
@@ -5,22 +5,24 @@
*/
?>
-<div class="content">
- <div class="two-thirds column">
- <div class="main">
+ <div class="content">
+ <div class="two-thirds column">
+ <div class="main">
<?php while ( have_posts() ) : the_post(); ?> <!-- the Loop -->
- <article id="post-<?php the_ID(); ?>">
-
+ <article id="post-<?php the_ID(); ?>">
+ <div class="title">
<a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>"><?php the_title('<h3>', '</h3>'); ?></a> <!--Post titles-->
-
- <p><?php the_content("Continue reading " . the_title('', '', false)); ?></p> <!--The Content-->
+ </div>
+
+ <?php the_content("Continue reading " . the_title('', '', false)); ?> <!--The Content-->
- <div class="meta"> <!--The Meta, Author, Date, Categories and Comments-->
+ <!--The Meta, Author, Date, Categories and Comments-->
+ <div class="meta">
Date posted: <?php echo get_the_date(); ?>
| Author: <?php echo get_the_author(); ?>
- | <?php comments_popup_link('No Comments &#187;', '1 Comment &#187;', '% Comments &#187;'); ?>
+ | <?php comments_popup_link('No Comments &#187;', '1 Comment &#187;', '% Comments &#187;'); ?>
<p>Categories: <?php the_category(' '); ?></p>
</div>
@@ -45,9 +47,9 @@
<?php if(is_page() || is_single()) :
comments_template( '', true );
-
endif; ?>
- </div> <!-- End Main -->
- </div> <!-- End two-thirds column -->
+
+ </div> <!-- End Main -->
+ </div> <!-- End two-thirds column -->
+ </div><!-- End Content -->
-</div><!-- End Content -->
View
17 menu.php
@@ -4,21 +4,22 @@
* @subpackage WP-Skeleton
*/
?>
-<div class="header">
+ <div class="header">
<div class="seven columns">
- <div class="logo"> <!-- the Logo -->
+ <div class="logo">
<a href="<?php echo home_url(); //make logo a home link?>">
- <h1 class="remove-bottom"><?php echo get_bloginfo('name');?></h1>
- <h5><?php echo get_bloginfo('description');?></h5>
+ <h1><?php echo get_bloginfo('name');?></h1>
+ <h5><?php echo get_bloginfo('description');?></h5>
</a>
</div>
</div>
<div class="eight columns">
- <div class="menu"> <!-- the Menu -->
- <?php wp_nav_menu( array( 'theme_location' => 'primary' ) ); ?>
- </div>
+ <div class="menu"> <!-- the Menu -->
+ <?php wp_nav_menu( array( 'theme_location' => 'primary' ) ); ?>
+ </div>
</div>
- </div> <!-- End blog header -->
+ </div> <!-- End blog header -->
+
View
8 sidebar.php
@@ -4,12 +4,12 @@
* @subpackage WP-Skeleton
*/
?>
-<div class="one-third column">
- <div class="sidebar"> <!-- the Sidebar -->
+ <div class="one-third column">
+ <div class="sidebar"> <!-- the Sidebar -->
<?php if ( is_active_sidebar( 'right-sidebar' ) ) : ?> <?php dynamic_sidebar( 'right-sidebar' ); ?>
<?php else : ?><p>You need to drag a widget into your sidebar in the WordPress Admin</p>
<?php endif; ?>
- </div>
- </div>
+ </div>
+ </div>
View
16 stylesheets/base.css
@@ -59,8 +59,6 @@
background: #fff;
font: 16px/1.5em "HelveticaNeue", "Helvetica Neue", Helvetica, Arial, sans-serif;
color: #444;
- -webkit-font-smoothing: antialiased; /* Fix for webkit rendering */
- -webkit-text-size-adjust: 100%;
}
@@ -71,10 +69,10 @@
font-family: "Georgia", "Times New Roman", Helvetica, Arial, sans-serif;
font-weight: normal; }
h1 a, h2 a, h3 a, h4 a, h5 a, h6 a { font-weight: inherit; }
- h1 { font-size: 46px; line-height: 50px; margin-bottom: 14px;}
- h2 { font-size: 35px; line-height: 40px; margin-bottom: 10px; }
- h3 { font-size: 28px; line-height: 34px; margin-bottom: 8px; }
- h4 { font-size: 21px; line-height: 30px; margin-bottom: 4px; }
+ h1 { font-size: 46px; line-height: 50px; }
+ h2 { font-size: 35px; line-height: 40px; }
+ h3 { font-size: 28px; line-height: 34px; }
+ h4 { font-size: 21px; line-height: 30px; }
h5 { font-size: 17px; line-height: 24px; }
h6 { font-size: 14px; line-height: 21px; }
.subheader { color: #777; }
@@ -216,9 +214,9 @@
/* #Misc
================================================== */
- .remove-bottom { margin-bottom: 0 !important; }
- .half-bottom { margin-bottom: 10px !important; }
- .add-bottom { margin-bottom: 20px !important; }
+.title{
+ padding-bottom: 15px;
+}
/* #Sidebar

0 comments on commit 5cbee4e

Please sign in to comment.