mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-22 09:07:59 +01:00
Update show_on_front to posts if there are no pages, just in case. see #14403.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16816 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
cab472f456
commit
0bee77d185
@ -64,7 +64,12 @@ include( './admin-header.php' );
|
||||
<?php if ( ! get_pages() ) : ?>
|
||||
<input name="show_on_front" type="hidden" value="posts" />
|
||||
<table class="form-table">
|
||||
<?php else :
|
||||
<?php
|
||||
if ( 'posts' != get_option( 'show_on_front' ) ) :
|
||||
update_option( 'show_on_front', 'posts' );
|
||||
endif;
|
||||
|
||||
else :
|
||||
if ( 'page' == get_option( 'show_on_front' ) && ! get_option( 'page_on_front' ) && ! get_option( 'page_for_posts' ) )
|
||||
update_option( 'show_on_front', 'posts' );
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user