Posted By

xcsteve99 on 12/18/12


Tagged


Versions (?)

Widgetizing WP Themes


 / Published in: PHP
 

URL: http://codex.wordpress.org/Widgetizing_Themes

Add First part to Functions.php

Add Second to where you want a smillcrobe

  1. <?php
  2. /**
  3.  * Register our sidebars and widgetized areas.
  4.  *
  5.  */
  6. function arphabet_widgets_init() {
  7.  
  8. register_sidebar( array(
  9. 'name' => 'Home right sidebar',
  10. 'id' => 'home_right_1',
  11. 'before_widget' => '<div>',
  12. 'after_widget' => '</div>',
  13. 'before_title' => '<h2 class="rounded">',
  14. 'after_title' => '</h2>',
  15. ) );
  16. }
  17. add_action( 'widgets_init', 'arphabet_widgets_init' );
  18. ?>
  19.  
  20.  
  21.  
  22.  
  23. <?php
  24. if ( dynamic_sidebar('home_right_1') ) :
  25. else :
  26. ?>
  27. <?php endif; ?>

Report this snippet  

You need to login to post a comment.