Tag Archives: add customer class to your navigation and work with your category

Customize WordPress Theme: Make header.php and footer.php — Part 2

<?php get_header();?>

<?php get_footer();?>

<?php get_sidebar();?>

Header.php meta change:

    <title><?php wp_title(”); ?><?php if(wp_title(”, false)) { echo ‘ | ‘; } ?> <?php bloginfo(‘name’); ?></title>    
    
    <meta http-equiv=”Content-Type” content=”text/html; charset=<?php bloginfo( ‘charset’ ); ?>” />

 

here is the why I said in the previous post why the categories is so important, in here you could use this in your header.php to pull out it as you navigation:

<?php
    $args=array(
      ‘orderby’ => ‘id’,
      ‘order’ => ‘ASC’
      );
    $categories=get_categories($args);
      foreach($categories as $category) {
        echo ‘<li class=”thisclass”><a href=”‘ . get_category_link( $category->term_id ) . ‘” title=”‘ . sprintf( __( “View all posts in %s” ), $category->name ) . ‘” ‘ . ‘>’ . $category->name.'</a></li>’;
        }
    ?>