Edit File by line
/home/barbar84/public_h.../wp-admin
File: options-writing.php
<?php
[0] Fix | Delete
/**
[1] Fix | Delete
* Writing settings administration panel.
[2] Fix | Delete
*
[3] Fix | Delete
* @package WordPress
[4] Fix | Delete
* @subpackage Administration
[5] Fix | Delete
*/
[6] Fix | Delete
[7] Fix | Delete
/** WordPress Administration Bootstrap */
[8] Fix | Delete
require_once __DIR__ . '/admin.php';
[9] Fix | Delete
[10] Fix | Delete
if ( ! current_user_can( 'manage_options' ) ) {
[11] Fix | Delete
wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) );
[12] Fix | Delete
}
[13] Fix | Delete
[14] Fix | Delete
$title = __( 'Writing Settings' );
[15] Fix | Delete
$parent_file = 'options-general.php';
[16] Fix | Delete
[17] Fix | Delete
get_current_screen()->add_help_tab(
[18] Fix | Delete
array(
[19] Fix | Delete
'id' => 'overview',
[20] Fix | Delete
'title' => __( 'Overview' ),
[21] Fix | Delete
'content' => '<p>' . __( 'You can submit content in several different ways; this screen holds the settings for all of them. The top section controls the editor within the dashboard, while the rest control external publishing methods. For more information on any of these methods, use the documentation links.' ) . '</p>' .
[22] Fix | Delete
'<p>' . __( 'You must click the Save Changes button at the bottom of the screen for new settings to take effect.' ) . '</p>',
[23] Fix | Delete
)
[24] Fix | Delete
);
[25] Fix | Delete
[26] Fix | Delete
/** This filter is documented in wp-admin/options.php */
[27] Fix | Delete
if ( apply_filters( 'enable_post_by_email_configuration', true ) ) {
[28] Fix | Delete
get_current_screen()->add_help_tab(
[29] Fix | Delete
array(
[30] Fix | Delete
'id' => 'options-postemail',
[31] Fix | Delete
'title' => __( 'Post Via Email' ),
[32] Fix | Delete
'content' => '<p>' . __( 'Post via email settings allow you to send your WordPress installation an email with the content of your post. You must set up a secret email account with POP3 access to use this, and any mail received at this address will be posted, so it&#8217;s a good idea to keep this address very secret.' ) . '</p>',
[33] Fix | Delete
)
[34] Fix | Delete
);
[35] Fix | Delete
}
[36] Fix | Delete
[37] Fix | Delete
/** This filter is documented in wp-admin/options-writing.php */
[38] Fix | Delete
if ( apply_filters( 'enable_update_services_configuration', true ) ) {
[39] Fix | Delete
get_current_screen()->add_help_tab(
[40] Fix | Delete
array(
[41] Fix | Delete
'id' => 'options-services',
[42] Fix | Delete
'title' => __( 'Update Services' ),
[43] Fix | Delete
'content' => '<p>' . __( 'If desired, WordPress will automatically alert various services of your new posts.' ) . '</p>',
[44] Fix | Delete
)
[45] Fix | Delete
);
[46] Fix | Delete
}
[47] Fix | Delete
[48] Fix | Delete
get_current_screen()->set_help_sidebar(
[49] Fix | Delete
'<p><strong>' . __( 'For more information:' ) . '</strong></p>' .
[50] Fix | Delete
'<p>' . __( '<a href="https://wordpress.org/support/article/settings-writing-screen/">Documentation on Writing Settings</a>' ) . '</p>' .
[51] Fix | Delete
'<p>' . __( '<a href="https://wordpress.org/support/">Support</a>' ) . '</p>'
[52] Fix | Delete
);
[53] Fix | Delete
[54] Fix | Delete
require_once ABSPATH . 'wp-admin/admin-header.php';
[55] Fix | Delete
?>
[56] Fix | Delete
[57] Fix | Delete
<div class="wrap">
[58] Fix | Delete
<h1><?php echo esc_html( $title ); ?></h1>
[59] Fix | Delete
[60] Fix | Delete
<form method="post" action="options.php">
[61] Fix | Delete
<?php settings_fields( 'writing' ); ?>
[62] Fix | Delete
[63] Fix | Delete
<table class="form-table" role="presentation">
[64] Fix | Delete
<?php if ( get_site_option( 'initial_db_version' ) < 32453 ) : ?>
[65] Fix | Delete
<tr>
[66] Fix | Delete
<th scope="row"><?php _e( 'Formatting' ); ?></th>
[67] Fix | Delete
<td><fieldset><legend class="screen-reader-text"><span><?php _e( 'Formatting' ); ?></span></legend>
[68] Fix | Delete
<label for="use_smilies">
[69] Fix | Delete
<input name="use_smilies" type="checkbox" id="use_smilies" value="1" <?php checked( '1', get_option( 'use_smilies' ) ); ?> />
[70] Fix | Delete
<?php _e( 'Convert emoticons like <code>:-)</code> and <code>:-P</code> to graphics on display' ); ?></label><br />
[71] Fix | Delete
<label for="use_balanceTags"><input name="use_balanceTags" type="checkbox" id="use_balanceTags" value="1" <?php checked( '1', get_option( 'use_balanceTags' ) ); ?> /> <?php _e( 'WordPress should correct invalidly nested XHTML automatically' ); ?></label>
[72] Fix | Delete
</fieldset></td>
[73] Fix | Delete
</tr>
[74] Fix | Delete
<?php endif; ?>
[75] Fix | Delete
<tr>
[76] Fix | Delete
<th scope="row"><label for="default_category"><?php _e( 'Default Post Category' ); ?></label></th>
[77] Fix | Delete
<td>
[78] Fix | Delete
<?php
[79] Fix | Delete
wp_dropdown_categories(
[80] Fix | Delete
array(
[81] Fix | Delete
'hide_empty' => 0,
[82] Fix | Delete
'name' => 'default_category',
[83] Fix | Delete
'orderby' => 'name',
[84] Fix | Delete
'selected' => get_option( 'default_category' ),
[85] Fix | Delete
'hierarchical' => true,
[86] Fix | Delete
)
[87] Fix | Delete
);
[88] Fix | Delete
?>
[89] Fix | Delete
</td>
[90] Fix | Delete
</tr>
[91] Fix | Delete
<?php
[92] Fix | Delete
$post_formats = get_post_format_strings();
[93] Fix | Delete
unset( $post_formats['standard'] );
[94] Fix | Delete
?>
[95] Fix | Delete
<tr>
[96] Fix | Delete
<th scope="row"><label for="default_post_format"><?php _e( 'Default Post Format' ); ?></label></th>
[97] Fix | Delete
<td>
[98] Fix | Delete
<select name="default_post_format" id="default_post_format">
[99] Fix | Delete
<option value="0"><?php echo get_post_format_string( 'standard' ); ?></option>
[100] Fix | Delete
<?php foreach ( $post_formats as $format_slug => $format_name ) : ?>
[101] Fix | Delete
<option<?php selected( get_option( 'default_post_format' ), $format_slug ); ?> value="<?php echo esc_attr( $format_slug ); ?>"><?php echo esc_html( $format_name ); ?></option>
[102] Fix | Delete
<?php endforeach; ?>
[103] Fix | Delete
</select>
[104] Fix | Delete
</td>
[105] Fix | Delete
</tr>
[106] Fix | Delete
<?php
[107] Fix | Delete
if ( get_option( 'link_manager_enabled' ) ) :
[108] Fix | Delete
?>
[109] Fix | Delete
<tr>
[110] Fix | Delete
<th scope="row"><label for="default_link_category"><?php _e( 'Default Link Category' ); ?></label></th>
[111] Fix | Delete
<td>
[112] Fix | Delete
<?php
[113] Fix | Delete
wp_dropdown_categories(
[114] Fix | Delete
array(
[115] Fix | Delete
'hide_empty' => 0,
[116] Fix | Delete
'name' => 'default_link_category',
[117] Fix | Delete
'orderby' => 'name',
[118] Fix | Delete
'selected' => get_option( 'default_link_category' ),
[119] Fix | Delete
'hierarchical' => true,
[120] Fix | Delete
'taxonomy' => 'link_category',
[121] Fix | Delete
)
[122] Fix | Delete
);
[123] Fix | Delete
?>
[124] Fix | Delete
</td>
[125] Fix | Delete
</tr>
[126] Fix | Delete
<?php endif; ?>
[127] Fix | Delete
[128] Fix | Delete
<?php
[129] Fix | Delete
do_settings_fields( 'writing', 'default' );
[130] Fix | Delete
do_settings_fields( 'writing', 'remote_publishing' ); // A deprecated section.
[131] Fix | Delete
?>
[132] Fix | Delete
</table>
[133] Fix | Delete
[134] Fix | Delete
<?php
[135] Fix | Delete
/** This filter is documented in wp-admin/options.php */
[136] Fix | Delete
if ( apply_filters( 'enable_post_by_email_configuration', true ) ) {
[137] Fix | Delete
?>
[138] Fix | Delete
<h2 class="title"><?php _e( 'Post via email' ); ?></h2>
[139] Fix | Delete
<p>
[140] Fix | Delete
<?php
[141] Fix | Delete
printf(
[142] Fix | Delete
/* translators: 1, 2, 3: Examples of random email addresses. */
[143] Fix | Delete
__( 'To post to WordPress by email, you must set up a secret email account with POP3 access. Any mail received at this address will be posted, so it&#8217;s a good idea to keep this address very secret. Here are three random strings you could use: %1$s, %2$s, %3$s.' ),
[144] Fix | Delete
sprintf( '<kbd>%s</kbd>', wp_generate_password( 8, false ) ),
[145] Fix | Delete
sprintf( '<kbd>%s</kbd>', wp_generate_password( 8, false ) ),
[146] Fix | Delete
sprintf( '<kbd>%s</kbd>', wp_generate_password( 8, false ) )
[147] Fix | Delete
);
[148] Fix | Delete
?>
[149] Fix | Delete
</p>
[150] Fix | Delete
[151] Fix | Delete
<table class="form-table" role="presentation">
[152] Fix | Delete
<tr>
[153] Fix | Delete
<th scope="row"><label for="mailserver_url"><?php _e( 'Mail Server' ); ?></label></th>
[154] Fix | Delete
<td><input name="mailserver_url" type="text" id="mailserver_url" value="<?php form_option( 'mailserver_url' ); ?>" class="regular-text code" />
[155] Fix | Delete
<label for="mailserver_port"><?php _e( 'Port' ); ?></label>
[156] Fix | Delete
<input name="mailserver_port" type="text" id="mailserver_port" value="<?php form_option( 'mailserver_port' ); ?>" class="small-text" />
[157] Fix | Delete
</td>
[158] Fix | Delete
</tr>
[159] Fix | Delete
<tr>
[160] Fix | Delete
<th scope="row"><label for="mailserver_login"><?php _e( 'Login Name' ); ?></label></th>
[161] Fix | Delete
<td><input name="mailserver_login" type="text" id="mailserver_login" value="<?php form_option( 'mailserver_login' ); ?>" class="regular-text ltr" /></td>
[162] Fix | Delete
</tr>
[163] Fix | Delete
<tr>
[164] Fix | Delete
<th scope="row"><label for="mailserver_pass"><?php _e( 'Password' ); ?></label></th>
[165] Fix | Delete
<td>
[166] Fix | Delete
<input name="mailserver_pass" type="text" id="mailserver_pass" value="<?php form_option( 'mailserver_pass' ); ?>" class="regular-text ltr" />
[167] Fix | Delete
</td>
[168] Fix | Delete
</tr>
[169] Fix | Delete
<tr>
[170] Fix | Delete
<th scope="row"><label for="default_email_category"><?php _e( 'Default Mail Category' ); ?></label></th>
[171] Fix | Delete
<td>
[172] Fix | Delete
<?php
[173] Fix | Delete
wp_dropdown_categories(
[174] Fix | Delete
array(
[175] Fix | Delete
'hide_empty' => 0,
[176] Fix | Delete
'name' => 'default_email_category',
[177] Fix | Delete
'orderby' => 'name',
[178] Fix | Delete
'selected' => get_option( 'default_email_category' ),
[179] Fix | Delete
'hierarchical' => true,
[180] Fix | Delete
)
[181] Fix | Delete
);
[182] Fix | Delete
?>
[183] Fix | Delete
</td>
[184] Fix | Delete
</tr>
[185] Fix | Delete
<?php do_settings_fields( 'writing', 'post_via_email' ); ?>
[186] Fix | Delete
</table>
[187] Fix | Delete
<?php } ?>
[188] Fix | Delete
[189] Fix | Delete
<?php
[190] Fix | Delete
/**
[191] Fix | Delete
* Filters whether to enable the Update Services section in the Writing settings screen.
[192] Fix | Delete
*
[193] Fix | Delete
* @since 3.0.0
[194] Fix | Delete
*
[195] Fix | Delete
* @param bool $enable Whether to enable the Update Services settings area. Default true.
[196] Fix | Delete
*/
[197] Fix | Delete
if ( apply_filters( 'enable_update_services_configuration', true ) ) {
[198] Fix | Delete
?>
[199] Fix | Delete
<h2 class="title"><?php _e( 'Update Services' ); ?></h2>
[200] Fix | Delete
[201] Fix | Delete
<?php if ( 1 == get_option( 'blog_public' ) ) : ?>
[202] Fix | Delete
[203] Fix | Delete
<p><label for="ping_sites">
[204] Fix | Delete
<?php
[205] Fix | Delete
printf(
[206] Fix | Delete
/* translators: %s: Documentation URL. */
[207] Fix | Delete
__( 'When you publish a new post, WordPress automatically notifies the following site update services. For more about this, see <a href="%s">Update Services</a> on the Codex. Separate multiple service URLs with line breaks.' ),
[208] Fix | Delete
__( 'https://wordpress.org/support/article/update-services/' )
[209] Fix | Delete
);
[210] Fix | Delete
?>
[211] Fix | Delete
</label></p>
[212] Fix | Delete
[213] Fix | Delete
<textarea name="ping_sites" id="ping_sites" class="large-text code" rows="3"><?php echo esc_textarea( get_option( 'ping_sites' ) ); ?></textarea>
[214] Fix | Delete
[215] Fix | Delete
<?php else : ?>
[216] Fix | Delete
[217] Fix | Delete
<p>
[218] Fix | Delete
<?php
[219] Fix | Delete
printf(
[220] Fix | Delete
/* translators: 1: Documentation URL, 2: URL to Reading Settings screen. */
[221] Fix | Delete
__( 'WordPress is not notifying any <a href="%1$s">Update Services</a> because of your site&#8217;s <a href="%2$s">visibility settings</a>.' ),
[222] Fix | Delete
__( 'https://wordpress.org/support/article/update-services/' ),
[223] Fix | Delete
'options-reading.php'
[224] Fix | Delete
);
[225] Fix | Delete
?>
[226] Fix | Delete
</p>
[227] Fix | Delete
[228] Fix | Delete
<?php endif; ?>
[229] Fix | Delete
<?php } // enable_update_services_configuration ?>
[230] Fix | Delete
[231] Fix | Delete
<?php do_settings_sections( 'writing' ); ?>
[232] Fix | Delete
[233] Fix | Delete
<?php submit_button(); ?>
[234] Fix | Delete
</form>
[235] Fix | Delete
</div>
[236] Fix | Delete
[237] Fix | Delete
<?php require_once ABSPATH . 'wp-admin/admin-footer.php'; ?>
[238] Fix | Delete
[239] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function