Make WordPress Core

Changeset 30541


Ignore:
Timestamp:
11/24/2014 05:38:44 AM (10 years ago)
Author:
DrewAPicture
Message:

Ensure inline code is markdown-escaped as such, HTML tags are removed from summaries, and that code snippets in descriptions are properly indented.

Affects DocBlocks for the following core elements:

  • Markdown-indent a code snippet in the description for _deprecated_argument()
  • Markdown-indent a code snippet in the description for wp_localize_script()
  • Backtick-escape HTML tags in two parameter descriptions for wp_register()
  • Various DocBlock formatting in the description for get_bloginfo()
  • Remove HTML tag from the summary for _wp_render_title_tag()
  • Backtick-escape a HTML tag in the description for get_archives_link()
  • Markdown-indent a code snippet in the description for wp_admin_css_color()
  • Markdown-indent a code snippet in the description for the welcome_panel hook

Props rarst.
See #30473.

Location:
trunk/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/index.php

    r29787 r30541  
    112112         * Add content to the welcome panel on the admin dashboard.
    113113         *
    114          * To remove the default welcome panel, use remove_action():
    115          * <code>remove_action( 'welcome_panel', 'wp_welcome_panel' );</code>
     114         * To remove the default welcome panel, use {@see remove_action()}:
     115         *
     116         *     remove_action( 'welcome_panel', 'wp_welcome_panel' );
    116117         *
    117118         * @since 3.5.0
  • trunk/src/wp-includes/functions.php

    r30532 r30541  
    34463446 * used by comparing it to its default value or evaluating whether it is empty.
    34473447 * For example:
    3448  * <code>
    3449  * if ( ! empty( $deprecated ) ) {
    3450  *  _deprecated_argument( __FUNCTION__, '3.0' );
    3451  * }
    3452  * </code>
     3448 *
     3449 *     if ( ! empty( $deprecated ) ) {
     3450 *         _deprecated_argument( __FUNCTION__, '3.0' );
     3451 *     }
     3452 *
    34533453 *
    34543454 * There is a hook deprecated_argument_run that will be called that can be used
  • trunk/src/wp-includes/functions.wp-scripts.php

    r29788 r30541  
    9191 *
    9292 * Accepts an associative array $l10n and creates a JavaScript object:
    93  * <code>
    94  * "$object_name" = {
    95  *       key: value,
    96  *       key: value,
    97  *       ...
    98  * }
    99  * </code>
     93 *
     94 *     "$object_name" = {
     95 *         key: value,
     96 *         key: value,
     97 *         ...
     98 *     }
     99 *
    100100 *
    101101 * @see WP_Dependencies::localize()
     
    104104 *
    105105 * @since 2.6.0
     106 *
     107 * @todo Documentation cleanup
    106108 *
    107109 * @param string $handle      Script handle the data will be attached to.
  • trunk/src/wp-includes/general-template.php

    r30224 r30541  
    512512 * @since 1.5.0
    513513 *
    514  * @param string $before Text to output before the link (defaults to <li>).
    515  * @param string $after Text to output after the link (defaults to </li>).
     514 * @param string $before Text to output before the link. Default `<li>`.
     515 * @param string $after Text to output after the link. Default `</li>`.
    516516 * @param boolean $echo Default to echo and not return the link.
    517517 * @return string|null String when retrieving, null when displaying.
     
    582582 *
    583583 * Some show parameter values are deprecated and will be removed in future
    584  * versions. These options will trigger the _deprecated_argument() function.
    585  * The deprecated blog info options are listed in the function contents.
     584 * versions. These options will trigger the {@see _deprecated_argument()}
     585 * function. The deprecated blog info options are listed in the function
     586 * contents.
    586587 *
    587588 * The possible values for the 'show' parameter are listed below.
    588  * <ol>
    589  * <li><strong>url</strong> - Blog URI to homepage.</li>
    590  * <li><strong>wpurl</strong> - Blog URI path to WordPress.</li>
    591  * <li><strong>description</strong> - Secondary title</li>
    592  * </ol>
     589 *
     590 * 1. url - Blog URI to homepage.
     591 * 2. wpurl - Blog URI path to WordPress.
     592 * 3. description - Secondary title
    593593 *
    594594 * The feed URL options can be retrieved from 'rdf_url' (RSS 0.91),
     
    715715
    716716/**
    717  * Display <title> tag with contents.
     717 * Display title tag with contents.
    718718 *
    719719 * @since 4.1.0
     
    12341234 * parameters.
    12351235 *
    1236  * The 'link' format uses the link HTML element with the <em>archives</em>
     1236 * The 'link' format uses the `<link>` HTML element with the **archives**
    12371237 * relationship. The before and after parameters are not used. The text
    12381238 * parameter is used to describe the link.
     
    12511251 *
    12521252 * @since 1.0.0
     1253 *
     1254 * @todo Properly document optional arguments as such
    12531255 *
    12541256 * @param string $url URL to archive.
     
    27072709 *
    27082710 * Allows a plugin to register a new admin colour scheme. For example:
    2709  * <code>
    2710  * wp_admin_css_color('classic', __('Classic'), admin_url("css/colors-classic.css"),
    2711  * array('#07273E', '#14568A', '#D54E21', '#2683AE'));
    2712  * </code>
     2711 *
     2712 *     wp_admin_css_color( 'classic', __( 'Classic' ), admin_url( "css/colors-classic.css" ), array(
     2713 *         '#07273E', '#14568A', '#D54E21', '#2683AE'
     2714 *     ) );
    27132715 *
    27142716 * @since 2.5.0
     2717 *
     2718 * @todo Properly document optional arguments as such
    27152719 *
    27162720 * @param string $key The unique key for this theme.
Note: See TracChangeset for help on using the changeset viewer.