responsive_mobile_widgets_init

Register widgetized area and update sidebar with default widgets.

Description

responsive_mobile_widgets_init(); 

Usage

  1. if ( !function_exists( 'responsive_mobile_widgets_init' ) ) { 
  2. require_once '/includes/functions-sidebar.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = responsive_mobile_widgets_init(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/includes/functions-sidebar.php  
  1. function responsive_mobile_widgets_init() { 
  2. register_sidebar( array( 
  3. 'name' => __( 'Main Sidebar', 'responsive-mobile' ),  
  4. 'description' => __( 'Area 1 - sidebar.php - Displays on Default, Blog, Blog Excerpt page templates', 'responsive-mobile' ),  
  5. 'id' => 'main-sidebar',  
  6. 'before_title' => '<div class="widget-title"><h3>',  
  7. 'after_title' => '</h3></div>',  
  8. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  9. 'after_widget' => '</div>' 
  10. ) ); 
  11.  
  12. register_sidebar( array( 
  13. 'name' => __( 'Right Sidebar', 'responsive-mobile' ),  
  14. 'description' => __( 'Area 2 - sidebar-right.php - Displays on Content/Sidebar page templates', 'responsive-mobile' ),  
  15. 'id' => 'right-sidebar',  
  16. 'before_title' => '<div class="widget-title"><h3>',  
  17. 'after_title' => '</h3></div>',  
  18. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  19. 'after_widget' => '</div>' 
  20. ) ); 
  21.  
  22. register_sidebar( array( 
  23. 'name' => __( 'Left Sidebar', 'responsive-mobile' ),  
  24. 'description' => __( 'Area 3 - sidebar-left.php - Displays on Sidebar/Content page templates', 'responsive-mobile' ),  
  25. 'id' => 'left-sidebar',  
  26. 'before_title' => '<div class="widget-title"><h3>',  
  27. 'after_title' => '</h3></div>',  
  28. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  29. 'after_widget' => '</div>' 
  30. ) ); 
  31.  
  32. register_sidebar( array( 
  33. 'name' => __( 'Left Sidebar Half Page', 'responsive-mobile' ),  
  34. 'description' => __( 'Area 4 - sidebar-left-half.php - Displays on Sidebar Half Page/Content page templates', 'responsive-mobile' ),  
  35. 'id' => 'left-sidebar-half',  
  36. 'before_title' => '<div class="widget-title"><h3>',  
  37. 'after_title' => '</h3></div>',  
  38. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  39. 'after_widget' => '</div>' 
  40. ) ); 
  41.  
  42. register_sidebar( array( 
  43. 'name' => __( 'Right Sidebar Half Page', 'responsive-mobile' ),  
  44. 'description' => __( 'Area 5 - sidebar-right-half.php - Displays on Content/Sidebar Half Page page templates', 'responsive-mobile' ),  
  45. 'id' => 'right-sidebar-half',  
  46. 'before_title' => '<div class="widget-title"><h3>',  
  47. 'after_title' => '</h3></div>',  
  48. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  49. 'after_widget' => '</div>' 
  50. ) ); 
  51.  
  52. register_sidebar( array( 
  53. 'name' => __( 'Home Widget 1', 'responsive-mobile' ),  
  54. 'description' => __( 'Area 6 - sidebar-home.php - Displays on the Home Page', 'responsive-mobile' ),  
  55. 'id' => 'home-widget-1',  
  56. 'before_title' => '<div id="widget-title-one" class="widget-title-home"><h3 class="widget-title-home">',  
  57. 'after_title' => '</h3></div>',  
  58. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  59. 'after_widget' => '</div>' 
  60. ) ); 
  61.  
  62. register_sidebar( array( 
  63. 'name' => __( 'Home Widget 2', 'responsive-mobile' ),  
  64. 'description' => __( 'Area 7 - sidebar-home.php - Displays on the Home Page', 'responsive-mobile' ),  
  65. 'id' => 'home-widget-2',  
  66. 'before_title' => '<div id="widget-title-two" class="widget-title-home"><h3 class="widget-title-home">',  
  67. 'after_title' => '</h3></div>',  
  68. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  69. 'after_widget' => '</div>' 
  70. ) ); 
  71.  
  72. register_sidebar( array( 
  73. 'name' => __( 'Home Widget 3', 'responsive-mobile' ),  
  74. 'description' => __( 'Area 8 - sidebar-home.php - Displays on the Home Page', 'responsive-mobile' ),  
  75. 'id' => 'home-widget-3',  
  76. 'before_title' => '<div id="widget-title-three" class="widget-title-home"><h3 class="widget-title-home">',  
  77. 'after_title' => '</h3></div>',  
  78. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  79. 'after_widget' => '</div>' 
  80. ) ); 
  81.  
  82. register_sidebar( array( 
  83. 'name' => __( 'Gallery Sidebar', 'responsive-mobile' ),  
  84. 'description' => __( 'Area 9 - sidebar-gallery.php - Displays on the page after an image has been clicked in a Gallery', 'responsive-mobile' ),  
  85. 'id' => 'gallery-widget',  
  86. 'before_title' => '<div class="widget-title"><h3>',  
  87. 'after_title' => '</h3></div>',  
  88. 'before_widget' => '<div id="%1$s" class="widget-wrapper %2$s">',  
  89. 'after_widget' => '</div>' 
  90. ) ); 
  91.  
  92. register_sidebar( array( 
  93. 'name' => __( 'Colophon Widget', 'responsive-mobile' ),  
  94. 'description' => __( 'Area 10 - sidebar-colophon.php, 100% width Footer widgets', 'responsive-mobile' ),  
  95. 'id' => 'colophon-widget',  
  96. 'before_title' => '<div class="widget-title"><h3>',  
  97. 'after_title' => '</h3></div>',  
  98. 'before_widget' => '<div id="%1$s" class="colophon-widget widget-wrapper %2$s">',  
  99. 'after_widget' => '</div>' 
  100. ) ); 
  101.  
  102. register_sidebar( array( 
  103. 'name' => __( 'Top Widget', 'responsive-mobile' ),  
  104. 'description' => __( 'Area 11 - sidebar-top.php - Displays on the right of the header', 'responsive-mobile' ),  
  105. 'id' => 'top-widget',  
  106. 'before_title' => '<div class="widget-title"><h3>',  
  107. 'after_title' => '</h3></div>',  
  108. 'before_widget' => '<div id="%1$s" class="responsive-mobile-top-widget %2$s">',  
  109. 'after_widget' => '</div>' 
  110. ) ); 
  111.  
  112. register_sidebar( array( 
  113. 'name' => __( 'Footer Widget', 'responsive-mobile' ),  
  114. 'description' => __( 'Area 12 - sidebar-footer.php - Maximum of 3 widgets per row', 'responsive-mobile' ),  
  115. 'id' => 'footer-widget',  
  116. 'before_title' => '<div class="widget-title"><h3>',  
  117. 'after_title' => '</h3></div>',  
  118. 'before_widget' => '<div id="%1$s" class="footer-widget %2$s">',  
  119. 'after_widget' => '</div>' 
  120. ) );