'Sidebar', 'id' => 'sidebar-1', 'class' => 'custom', 'description' => 'Standard Sidebar', 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => 'Footer Left', 'id' => 'footer-1', 'class' => 'custom', 'description' => 'Widget area in the left side of footer', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => 'Footer Middle', 'id' => 'footer-2', 'class' => 'custom', 'description' => 'Widget area in the middle the of the footer', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); register_sidebar( array( 'name' => 'Footer Right', 'id' => 'footer-3', 'class' => 'custom', 'description' => 'Widget area in the right side of the footer', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', ) ); } add_action('widgets_init', 'blogga_register_widgets'); /* ========================== BLOG LOOP CUSTOM FUNCTIONS ========================== */ function blogga_posted_meta_top() { return the_modified_date( 'Y-m-d', '', '' ) . comments_number( '0', '1', '%'); } function blogga_posted_meta_footer() { $categories = get_the_category(); $separator = ', '; $output = ''; $i = 1; if( !empty($categories) ): foreach( $categories as $category ): if( $i > 1 ): $output .= $separator; endif; $output .= '' . esc_html( $category->name ) .''; $i++; endforeach; endif; $comments_num = get_comments_number(); if( comments_open() ){ if( $comments_num == 0 ){ $comments = __('No Comments', 'blogga'); } elseif ( $comments_num > 1 ){ $comments= $comments_num . __(' Comments', 'blogga'); } else { $comments = __('1 Comment', 'blogga'); } $comments = ''. $comments .''; } else { $comments = __('Comments are closed', 'blogga'); } return '' . $output . '' . get_the_tag_list('', ' ', '' ) . ''. $comments .''; } function blogga_posted_meta_single() { $categories = get_the_category(); $separator = ', '; $output = ''; $i = 1; if( !empty($categories) ): foreach( $categories as $category ): if( $i > 1 ): $output .= $separator; endif; $output .= '' . esc_html( $category->name ) .''; $i++; endforeach; endif; $comments_num = get_comments_number(); if( comments_open() ){ if( $comments_num == 0 ){ $comments = __('No Comments', 'blogga'); } elseif ( $comments_num > 1 ){ $comments= $comments_num . __(' Comments', 'blogga'); } else { $comments = __('1 Comment', 'blogga'); } $comments = ''. $comments .''; } else { $comments = __('Comments are closed', 'blogga'); } return the_date('Y-m-d','', '') . '' . $output . '' . get_the_tag_list('', ' ', '' ) . ''. $comments .''; }