Advertisement
srikat

functions.php

May 2nd, 2014
189
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.17 KB | None | 0 0
  1. //* Enqueue Google fonts
  2. add_action( 'wp_enqueue_scripts', 'sp_load_google_fonts' );
  3. function sp_load_google_fonts() {
  4.     wp_enqueue_style( 'google-fonts', '//fonts.googleapis.com/css?family=Open+Sans|Playball', array(), CHILD_THEME_VERSION );
  5. }
  6.  
  7. genesis_register_sidebar( array(
  8.     'id'            => 'home-featured',
  9.     'name'          => 'Home Featured',
  10.     'description'   => 'This is the home featured section'
  11. ) );
  12.  
  13. genesis_register_sidebar( array(
  14.     'id'            => 'home-welcome',
  15.     'name'          => 'Home Welcome',
  16.     'description'   => 'This is the home welcome section'
  17. ) );
  18.  
  19. add_action( 'genesis_after_header', 'sk_home_featured' );
  20. function sk_home_featured() {
  21.  
  22.     if ( ! is_front_page() ) {
  23.         return;
  24.     }
  25.  
  26.     echo '<div class="home-featured"><div class="wrap">';
  27.         genesis_widget_area( 'home-featured', array(
  28.             'before'    => '<div class="widget-area">',
  29.             'after'     => '</div>',
  30.         ) );
  31.     echo '</div></div>';
  32.  
  33. }
  34.  
  35. add_action( 'genesis_after_header', 'sk_welcome' );
  36. function sk_welcome() {
  37.  
  38.     if ( ! is_front_page() ) {
  39.         return;
  40.     }
  41.  
  42.     genesis_widget_area( 'home-welcome', array(
  43.         'before'    => '<div class="welcome widget-area"><div class="wrap">',
  44.         'after'     => '</div></div>',
  45.     ) );
  46.  
  47. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement