Advertisement
srikat

front-page.php

May 13th, 2015
262
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.93 KB | None | 0 0
  1. <?php
  2.  
  3. add_filter( 'genesis_attr_site-inner', 'sk_attributes_site_inner' );
  4. /**
  5. * Add attributes for site-inner element.
  6. *
  7. * @since 2.0.0
  8. *
  9. * @param array $attributes Existing attributes.
  10. *
  11. * @return array Amended attributes.
  12. */
  13. function sk_attributes_site_inner( $attributes ) {
  14.  
  15. $attributes['role'] = 'main';
  16. $attributes['itemprop'] = 'mainContentOfPage';
  17.  
  18. return $attributes;
  19.  
  20. }
  21.  
  22. // Remove div.site-inner's div.wrap
  23. add_filter( 'genesis_structural_wrap-site-inner', '__return_empty_string' );
  24.  
  25. // Display header
  26. get_header();
  27.  
  28. // Content
  29. // Display Page Title and Content coming from WP editor
  30. // echo '<div class="home-section page-content">';
  31. // genesis_standard_loop();
  32. // echo '</div>';
  33.  
  34. global $post;
  35. // $content = $post->post_content;
  36. // if( $content ) {
  37. // echo wpautop( $content );
  38. echo apply_filters( 'the_content', $post->post_content );
  39. // }
  40.  
  41.  
  42. // Display Footer
  43. get_footer();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement