When no pages are present add a hidden input field so that the show_on_front option is not blanked. Fixes is_front_page return value in an edge case. props sivel, fixes #12737, fixes #9105.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14362 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
0b597379e4
commit
a4d7fcdbf8
|
@ -25,8 +25,11 @@ include( './admin-header.php' );
|
||||||
<form name="form1" method="post" action="options.php">
|
<form name="form1" method="post" action="options.php">
|
||||||
<?php settings_fields( 'reading' ); ?>
|
<?php settings_fields( 'reading' ); ?>
|
||||||
|
|
||||||
|
<?php if ( ! get_pages() ) : ?>
|
||||||
|
<input name="show_on_front" type="hidden" value="posts" />
|
||||||
|
<table class="form-table">
|
||||||
|
<?php else : ?>
|
||||||
<table class="form-table">
|
<table class="form-table">
|
||||||
<?php if ( get_pages() ): ?>
|
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
<th scope="row"><?php _e( 'Front page displays' ); ?></th>
|
<th scope="row"><?php _e( 'Front page displays' ); ?></th>
|
||||||
<td id="front-static-pages"><fieldset><legend class="screen-reader-text"><span><?php _e( 'Front page displays' ); ?></span></legend>
|
<td id="front-static-pages"><fieldset><legend class="screen-reader-text"><span><?php _e( 'Front page displays' ); ?></span></legend>
|
||||||
|
|
Loading…
Reference in New Issue