Make WordPress Core

Changeset 21872


Ignore:
Timestamp:
09/16/2012 06:33:19 PM (12 years ago)
Author:
nacin
Message:

Docs for options_reading_blog_charset(). props SergeyBiryukov, fixes #21886.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/options-reading.php

    r21856 r21872  
    1919 * Display JavaScript on the page.
    2020 *
    21  * @package WordPress
    22  * @subpackage Reading_Settings_Screen
     21 * @since 3.5.0
    2322 */
    2423function options_reading_add_js() {
     
    4140}
    4241add_action('admin_head', 'options_reading_add_js');
     42
     43/**
     44 * Render the blog charset setting.
     45 *
     46 * @since 3.5.0
     47 */
     48function options_reading_blog_charset() {
     49    echo '<input name="blog_charset" type="text" id="blog_charset" value="' . esc_attr( get_option( 'blog_charset' ) ) . '" class="regular-text" />';
     50    echo '<p class="description">' . __( 'The <a href="http://codex.wordpress.org/Glossary#Character_set">character encoding</a> of your site (UTF-8 is recommended)' ) . '</p>';
     51}
    4352
    4453get_current_screen()->add_help_tab( array(
     
    7483<?php
    7584settings_fields( 'reading' );
    76 
    77 function options_reading_blog_charset() {
    78     echo '<input name="blog_charset" type="text" id="blog_charset" value="' . esc_attr( get_option( 'blog_charset' ) ) . '" class="regular-text" />';
    79     echo '<p class="description">' . __( 'The <a href="http://codex.wordpress.org/Glossary#Character_set">character encoding</a> of your site (UTF-8 is recommended)' ) . '</p>';
    80 }
    8185
    8286if ( ! in_array( get_option( 'blog_charset' ), array( 'utf8', 'utf-8', 'UTF8', 'UTF-8' ) ) )
Note: See TracChangeset for help on using the changeset viewer.