<?php
/*
Template Name: Archives
*/
?>

<?php get_header(); ?>

			<!--BEGIN #page-title-wrap--> 
            <div id="page-title-wrap">

                <h1 class="page-title"><?php the_title(); ?></h1>
            
            <!--END #page-title-wrap-->
            </div>
            
            <!--BEGIN #posts-wrap-->
            <div id="posts-wrap" class="clearfix">
			
                <!--BEGIN #primary .hfeed-->
                <div id="primary" class="hfeed">			
                <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
                    
                    <!--BEGIN .hentry -->
                    <div <?php post_class(); ?> id="post-<?php the_ID(); ?>">	
                    
                        <!--BEGIN .entry-content -->
                        <div class="entry-content">
                            <?php the_content(__('<br /><br />Continue Reading &rarr;', 'framework')); ?>
                            
                            <!--BEGIN .archive-lists -->
                            <div class="archive-lists">
                                
                                <h4><?php _e('Last 30 Posts', 'framework') ?></h4>
                                
                                <ul>
                                <?php $archive_30 = get_posts('numberposts=30');
                                foreach($archive_30 as $post) : ?>
                                    <li><a href="<?php the_permalink(); ?>"><?php the_title();?></a></li>
                                <?php endforeach; ?>
                                </ul>
                                
                                <h4><?php _e('Archives by Month:', 'framework') ?></h4>
                                
                                <ul>
                                    <?php wp_get_archives('type=monthly'); ?>
                                </ul>
                    
                                <h4><?php _e('Archives by Subject:', 'framework') ?></h4>
                                
                                <ul>
                                    <?php wp_list_categories( 'title_li=' ); ?>
                                </ul>
                            
                            <!--END .archive-lists -->
                            </div>
                            
                        <!--END .entry-content -->
                        </div>
                        
    
                    <!--END .hentry-->  
                    </div>
    
                    <?php endwhile; ?>
    
                <?php endif; ?>
                <!--END #primary .hfeed-->
                </div>
                
                <?php get_sidebar(); ?>
                
            </div>
            <!--END #posts-wrap-->

<?php get_footer(); ?>