Advertisement
Guest User

Untitled

a guest
Jun 27th, 2012
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.90 KB | None | 0 0
  1. <?php
  2. $max=WEBFISH_COLUMNS_INDEX;
  3. $type="index";
  4. if(is_home()){
  5. $max=WEBFISH_COLUMNS_INDEX;
  6. $type="index";
  7. }
  8. elseif(is_front_page()){
  9. $max=WEBFISH_COLUMNS_FRONT_PAGE;
  10. $type="frontpage";
  11. }
  12. elseif(is_page()){
  13. $max=WEBFISH_COLUMNS_PAGE;
  14. $type="page";
  15. }
  16. elseif(is_single()){
  17. $max=WEBFISH_COLUMNS_SINGLE;
  18. $type="single";
  19. }
  20.  
  21. for($i=1;$i<$max;$i++):?>
  22. <div id="sb<?php echo $i;?>_wrap" class="sb_wrap sb_<?php echo $type;?>_wrap">
  23. <div id="sb<?php echo $i;?>_top" class="sb_top sb_<?php echo $type;?>_top"></div>
  24. <div id="sidebar<?php echo $i;?>" class="sidebar widget-area sb_<?php echo $type;?>">
  25. <ul>
  26. <?php
  27. if ( is_active_sidebar( "sidebar$i-$type" )){
  28. dynamic_sidebar("sidebar$i-$type");
  29. }
  30. elseif( is_active_sidebar( "sidebar-$type" )){
  31. dynamic_sidebar("sidebar-$type");
  32. }
  33. elseif( is_active_sidebar( "sidebar$i" )){
  34. dynamic_sidebar("sidebar$i");
  35. }
  36. elseif( is_active_sidebar( "sidebar" )){
  37. dynamic_sidebar("sidebar");
  38. }
  39. else{
  40. ?>
  41.  
  42. <li id="pages" class="widget-container widget_search">
  43. <h5 class="widgettitle"><?php _e( 'Pages', 'webfish_theme_angler' ); ?></h5>
  44. <ul>
  45. <?php wp_list_pages(array("depth"=>"1","title_li"=>'')); ?>
  46. </ul>
  47. </li>
  48.  
  49. <li id="archives" class="widget-container">
  50. <h5 class="widgettitle"><?php _e( 'Archives', 'webfish_theme_angler' ); ?></h5>
  51. <ul>
  52. <?php wp_get_archives( 'type=monthly' ); ?>
  53. </ul>
  54. </li>
  55.  
  56. <li id="meta" class="widget-container">
  57. <h5 class="widgettitle"><?php _e( 'Meta', 'webfish_theme_angler' ); ?></h5>
  58. <ul>
  59. <?php wp_register(); ?>
  60. <li><?php wp_loginout(); ?></li>
  61. <?php wp_meta(); ?>
  62. </ul>
  63. </li>
  64. <?php }
  65. ?>
  66.  
  67. </ul>
  68. </div>
  69. <div id="sb<?php echo $i;?>_bottom" class="sb_bottom sb_<?php echo $type;?>_bottom"></div>
  70. <div class="clear"></div>
  71. </div><!-- sb_wrap -->
  72. <?php endfor;?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement