Don't like ads? PRO users don't see any ads ;-)
Guest

homesidebar.php

By: a guest on Oct 10th, 2010  |  syntax: PHP  |  size: 1.28 KB  |  hits: 100  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1.    <?php
  2. global $options;
  3. foreach ($options as $value) {
  4. if (get_settings( $value['id'] ) === FALSE) { $$value['id'] = $value['std']; } else { $$value['id'] = get_settings( $value['id'] ); } }
  5. ?>
  6.         <ul class="sidebar">
  7.         <li>
  8.         <h2><?php _e('Blogg'); ?></h2>
  9.                 <ul>
  10.            
  11.             <?php $my_query = new WP_Query('showposts='.$bz_blogno.'&category_name='.$bz_blog); while ($my_query->have_posts()) : $my_query->the_post(); ?>
  12.        
  13.         <li>              
  14.    <div class="testi">
  15.         <div class="testi_img"><?php mtheme_thumb1(); ?></div>
  16. <h6 class="tits"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php echo shorten_text(get_the_title(), 50); ?></a></h6>
  17. <h3 class="slide_small"><?php the_time('d M Y'); ?></h3>    
  18.     <p><?php the_excerpt("Les mer"); ?> </p>
  19.  
  20.         </div>
  21.  
  22.  
  23.         </li>  
  24.  
  25.        
  26.         <?php endwhile; ?>
  27.            
  28.         </ul>
  29.         </li>
  30.         <?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar("Home Sidebar") ) : else : ?>
  31.        
  32.         <li>
  33.         <h2><?php _e('Archives'); ?></h2>
  34.             <ul>
  35.             <?php wp_get_archives('type=monthly'); ?>
  36.             </ul>
  37.         </li>
  38.        
  39.         <?php endif; ?>
  40.         </ul>