<?php
if ( function_exists('register_sidebar') )
    register_sidebar(array(
        'before_widget' => '',
        'after_widget' => '</div>',
        'before_title' => '<div class="title"> <h2>',
        'after_title' => '</h2> </div> <div class="post">',
    ));
    function widget_mytheme_search() {
?>
	  <div class="title">
        <h2>Browse</h2>
      </div>
	  <div class="post">
        <select name="archivemenu" onChange="document.location.href=this.options[this.selectedIndex].value;">
          <option value="">Monatsarchiv</option>
          <?php get_archives('monthly','','option','','',''); ?>
        </select>		
        <?php include (TEMPLATEPATH . '/searchform.php'); ?>
	  </div>
	  
<?php
}
if ( function_exists('register_sidebar_widget') )
    register_sidebar_widget(__('Suche'), 'widget_mytheme_search');

    function widget_mytheme_links() {
?>
	  <div class="title">
        <h2>Links</h2>
      </div>
	  <div class="post">
	    <ul>
	      <?php wp_get_links(1); ?>
		</ul>
      </div>
	  
<?php
}
if ( function_exists('register_sidebar_widget') )
    register_sidebar_widget(__('Links'), 'widget_mytheme_links');
	
	    function widget_mytheme_pages() {
?>
	  <div class="title">
        <h2>Seiten</h2>
      </div>
	  <div class="post">
	    <ul class="buttons">
	      <?php wp_list_pages('title_li='); ?>
		</ul>
      </div>
	  
<?php
}
if ( function_exists('register_sidebar_widget') )
    register_sidebar_widget(__('Seiten'), 'widget_mytheme_pages');

?>