Guest User

Untitled

a guest
Dec 10th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. $pageInformation = get_page_by_title('Information');
  2. $pageBlog = get_page_by_title('Blog');
  3. $pageMessage = get_page_by_title('Message');
  4.  
  5. // Set the "Front page displays" reading options
  6. $show_on_front = get_option('show_on_front');
  7. if ( $show_on_front != 'page' ){
  8. update_option( 'show_on_front', 'page' );
  9. }
  10. $page_on_front = get_option('page_on_front');
  11. if ( $page_on_front != $pageInformation->ID ){
  12. update_option( 'page_on_front', $pageInformation->ID );
  13. }
  14. $page_for_posts = get_option('page_for_posts');
  15. if ( $page_for_posts != $pageBlog->ID ){
  16. update_option( 'page_for_posts', $pageBlog->ID );
  17. }
Add Comment
Please, Sign In to add comment