WordPress.org

Make WordPress Core

Ticket #14783: since-tags.diff

File since-tags.diff, 9.8 KB (added by duck_, 4 years ago)

Alot of @since unkown

  • wp-admin/includes/bookmark.php

     
    77 */ 
    88 
    99/** 
    10  * {@internal Missing Short Description}} 
     10 * Add a link to using values provided in $_POST. 
    1111 * 
    12  * @since unknown 
     12 * @since 2.0.0 
    1313 * 
    14  * @return unknown 
     14 * @return int|WP_Error Value 0 or WP_Error on failure. The link ID on success. 
    1515 */ 
    1616function add_link() { 
    1717        return edit_link(); 
    1818} 
    1919 
    2020/** 
    21  * {@internal Missing Short Description}} 
     21 * Update or insert a link using values provided in $_POST. 
    2222 * 
    23  * @since unknown 
     23 * @since 2.0.0 
    2424 * 
    25  * @param unknown_type $link_id 
    26  * @return unknown 
     25 * @param int $link_id Optional. ID of the link to edit. 
     26 * @return int|WP_Error Value 0 or WP_Error on failure. The link ID on success. 
    2727 */ 
    28 function edit_link( $link_id = '' ) { 
    29         if (!current_user_can( 'manage_links' )) 
    30                 wp_die( __( 'Cheatin’ uh?' )); 
     28function edit_link( $link_id = 0 ) { 
     29        if ( !current_user_can( 'manage_links' ) ) 
     30                wp_die( __( 'Cheatin’ uh?' ) ); 
    3131 
    3232        $_POST['link_url'] = esc_html( $_POST['link_url'] ); 
    3333        $_POST['link_url'] = esc_url($_POST['link_url']); 
     
    3939 
    4040        if ( !empty( $link_id ) ) { 
    4141                $_POST['link_id'] = $link_id; 
    42                 return wp_update_link( $_POST); 
     42                return wp_update_link( $_POST ); 
    4343        } else { 
    44                 return wp_insert_link( $_POST); 
     44                return wp_insert_link( $_POST ); 
    4545        } 
    4646} 
    4747 
    4848/** 
    49  * {@internal Missing Short Description}} 
     49 * Retrieve the default link for editing. 
    5050 * 
    51  * @since unknown 
     51 * @since 2.0.0 
    5252 * 
    53  * @return unknown 
     53 * @return object Default link 
    5454 */ 
    5555function get_default_link_to_edit() { 
    5656        if ( isset( $_GET['linkurl'] ) ) 
    57                 $link->link_url = esc_url( $_GET['linkurl']); 
     57                $link->link_url = esc_url( $_GET['linkurl'] ); 
    5858        else 
    5959                $link->link_url = ''; 
    6060 
    6161        if ( isset( $_GET['name'] ) ) 
    62                 $link->link_name = esc_attr( $_GET['name']); 
     62                $link->link_name = esc_attr( $_GET['name'] ); 
    6363        else 
    6464                $link->link_name = ''; 
    6565 
     
    6969} 
    7070 
    7171/** 
    72  * {@internal Missing Short Description}} 
     72 * Delete link specified from database 
    7373 * 
    74  * @since unknown 
     74 * @since 2.0.0 
    7575 * 
    76  * @param unknown_type $link_id 
    77  * @return unknown 
     76 * @param int $link_id ID of the link to delete 
     77 * @return bool True 
    7878 */ 
    7979function wp_delete_link( $link_id ) { 
    8080        global $wpdb; 
     
    9393} 
    9494 
    9595/** 
    96  * {@internal Missing Short Description}} 
     96 * Retrieves the link categories associated with the link specified. 
    9797 * 
    98  * @since unknown 
     98 * @since 2.1.0 
    9999 * 
    100  * @param unknown_type $link_id 
    101  * @return unknown 
     100 * @param int $link_id Link ID to look up 
     101 * @return array The requested link's categories 
    102102 */ 
    103103function wp_get_link_cats( $link_id = 0 ) { 
    104104 
     
    108108} 
    109109 
    110110/** 
    111  * {@internal Missing Short Description}} 
     111 * Retrieve link data based on ID. 
    112112 * 
    113  * @since unknown 
     113 * @since 2.0.0 
    114114 * 
    115  * @param unknown_type $link_id 
    116  * @return unknown 
     115 * @param int $link_id ID of link to retrieve 
     116 * @return object Link for editing 
    117117 */ 
    118118function get_link_to_edit( $link_id ) { 
    119119        return get_bookmark( $link_id, OBJECT, 'edit' ); 
    120120} 
    121121 
    122122/** 
    123  * {@internal Missing Short Description}} 
     123 * This function inserts/updates links into/in the database.  
    124124 * 
    125  * @since unknown 
     125 * @since 2.0.0 
    126126 * 
    127  * @param unknown_type $linkdata 
    128  * @return unknown 
     127 * @param array $linkdata Elements that make up the link to insert. 
     128 * @param bool $wp_error Optional. If true return WP_Error object on failure. 
     129 * @return int|WP_Error Value 0 or WP_Error on failure. The link ID on success. 
    129130 */ 
    130131function wp_insert_link( $linkdata, $wp_error = false ) { 
    131132        global $wpdb; 
     
    181182                $link_rel = ''; 
    182183 
    183184        // Make sure we set a valid category 
    184         if ( ! isset( $link_category ) ||0 == count( $link_category ) || !is_array( $link_category ) ) { 
     185        if ( ! isset( $link_category ) || 0 == count( $link_category ) || !is_array( $link_category ) ) { 
    185186                $link_category = array( get_option( 'default_link_category' ) ); 
    186187        } 
    187188 
     
    215216} 
    216217 
    217218/** 
    218  * {@internal Missing Short Description}} 
     219 * Update link with the specified link categories. 
    219220 * 
    220  * @since unknown 
     221 * @since 2.1.0 
    221222 * 
    222  * @param unknown_type $link_id 
    223  * @param unknown_type $link_categories 
     223 * @param int $link_id ID of link to update 
     224 * @param array $link_categories Array of categories to  
    224225 */ 
    225226function wp_set_link_cats( $link_id = 0, $link_categories = array() ) { 
    226227        // If $link_categories isn't already an array, make it one: 
     
    233234        wp_set_object_terms( $link_id, $link_categories, 'link_category' ); 
    234235 
    235236        clean_bookmark_cache( $link_id ); 
    236 }       // wp_set_link_cats() 
     237} 
    237238 
    238239/** 
    239  * {@internal Missing Short Description}} 
     240 * Update a link in the database. 
    240241 * 
    241  * @since unknown 
     242 * @since 2.0.0 
    242243 * 
    243  * @param unknown_type $linkdata 
    244  * @return unknown 
     244 * @param array $linkdata Link data to update. 
     245 * @return int|WP_Error Value 0 or WP_Error on failure. The updated link ID on success. 
    245246 */ 
    246247function wp_update_link( $linkdata ) { 
    247248        $link_id = (int) $linkdata['link_id']; 
  • wp-admin/includes/comment.php

     
    99/** 
    1010 * {@internal Missing Short Description}} 
    1111 * 
    12  * @since unknown 
     12 * @since 2.0.0 
    1313 * @uses $wpdb 
    1414 * 
    15  * @param string $comment_author 
    16  * @param string $comment_date 
     15 * @param string $comment_author Author of the comment 
     16 * @param string $comment_date Date of the comment 
    1717 * @return mixed Comment ID on success. 
    1818 */ 
    1919function comment_exists($comment_author, $comment_date) { 
     
    2727} 
    2828 
    2929/** 
    30  * {@internal Missing Short Description}} 
     30 * Update a comment with values provided in $_POST. 
    3131 * 
    32  * @since unknown 
     32 * @since 2.0.0 
    3333 */ 
    3434function edit_comment() { 
    35  
    3635        $comment_post_ID = (int) $_POST['comment_post_ID']; 
    3736 
    3837        if (!current_user_can( 'edit_post', $comment_post_ID )) 
    39                 wp_die( __('You are not allowed to edit comments on this post, so you cannot edit this comment.' )); 
     38                wp_die( __('You are not allowed to edit comments on this post, so you cannot edit this comment.' ) ); 
    4039 
    4140        $_POST['comment_author'] = $_POST['newcomment_author']; 
    4241        $_POST['comment_author_email'] = $_POST['newcomment_author_email']; 
     
    5251                } 
    5352        } 
    5453 
    55         if (!empty ( $_POST['edit_date'] ) ) { 
     54        if ( !empty ( $_POST['edit_date'] ) ) { 
    5655                $aa = $_POST['aa']; 
    5756                $mm = $_POST['mm']; 
    5857                $jj = $_POST['jj']; 
     
    6665                $_POST['comment_date'] = "$aa-$mm-$jj $hh:$mn:$ss"; 
    6766        } 
    6867 
    69         wp_update_comment( $_POST); 
     68        wp_update_comment( $_POST ); 
    7069} 
    7170 
    7271/** 
    7372 * {@internal Missing Short Description}} 
    7473 * 
    75  * @since unknown 
     74 * @since 2.0.0 
    7675 * 
    77  * @param unknown_type $id 
    78  * @return unknown 
     76 * @param int $id ID of comment to retrieve 
     77 * @return bool|object Comment if found. False on failure. 
    7978 */ 
    8079function get_comment_to_edit( $id ) { 
    8180        if ( !$comment = get_comment($id) ) 
     
    9897/** 
    9998 * Get the number of pending comments on a post or posts 
    10099 * 
    101  * @since unknown 
     100 * @since 2.3.0 
    102101 * @uses $wpdb 
    103102 * 
    104103 * @param int|array $post_id Either a single Post ID or an array of Post IDs 
  • wp-admin/includes/dashboard.php

     
    99/** 
    1010 * Registers dashboard widgets. 
    1111 * 
    12  * handles POST data, sets up filters. 
     12 * Handles POST data, sets up filters. 
    1313 * 
    14  * @since unknown 
     14 * @since 2.5.0 
    1515 */ 
    1616function wp_dashboard_setup() { 
    1717        global $wp_registered_widgets, $wp_registered_widget_controls, $wp_dashboard_control_callbacks; 
     
    150150/** 
    151151 * Displays the dashboard. 
    152152 * 
    153  * @since unknown 
     153 * @since 2.5.0 
    154154 */ 
    155155function wp_dashboard() { 
    156156        global $screen_layout_columns; 
     
    517517/** 
    518518 * Display recent comments dashboard widget content. 
    519519 * 
    520  * @since unknown 
     520 * @since 2.5.0 
    521521 */ 
    522522function wp_dashboard_recent_comments() { 
    523523        global $wpdb; 
     
    703703/** 
    704704 * Display incoming links dashboard widget content. 
    705705 * 
    706  * @since unknown 
     706 * @since 2.5.0 
    707707 */ 
    708708function wp_dashboard_incoming_links_output() { 
    709709        $widgets = get_option( 'dashboard_widget_options' ); 
     
    795795/** 
    796796 * {@internal Missing Short Description}} 
    797797 * 
    798  * @since unknown 
     798 * @since 2.5.0 
    799799 * 
    800  * @param int $widget_id 
     800 * @param string $widget_id 
    801801 */ 
    802802function wp_dashboard_rss_output( $widget_id ) { 
    803803        $widgets = get_option( 'dashboard_widget_options' ); 
     
    817817/** 
    818818 * Display secondary dashboard RSS widget feed. 
    819819 * 
    820  * @since unknown 
     820 * @since 2.5.0 
    821821 * 
    822822 * @return unknown 
    823823 */ 
     
    852852/** 
    853853 * Display plugins most popular, newest plugins, and recently updated widget text. 
    854854 * 
    855  * @since unknown 
     855 * @since 2.5.0 
    856856 */ 
    857857function wp_dashboard_plugins_output() { 
    858858        $popular = fetch_feed( 'http://wordpress.org/extend/plugins/rss/browse/popular/' ); 
     
    938938 * echoes out output for this widget. If not cache, echo a "Loading..." stub 
    939939 * which is later replaced by AJAX call (see top of /wp-admin/index.php) 
    940940 * 
    941  * @since unknown 
     941 * @since 2.5.0 
    942942 * 
    943  * @param int $widget_id 
     943 * @param string $widget_id 
    944944 * @param callback $callback 
    945945 * @param array $check_urls RSS feeds 
    946946 * @return bool False on failure. True on success. 
     
    981981/** 
    982982 * Calls widget control callback. 
    983983 * 
    984  * @since unknown 
     984 * @since 2.5.0 
    985985 * 
    986986 * @param int $widget_control_id Registered Widget ID. 
    987987 */ 
     
    999999 * Sets up $args to be used as input to wp_widget_rss_form(). Handles POST data 
    10001000 * from RSS-type widgets. 
    10011001 * 
    1002  * @since unknown 
     1002 * @since 2.5.0 
    10031003 * 
    1004  * @param string widget_id 
    1005  * @param array form_inputs 
     1004 * @param string $widget_id 
     1005 * @param array $form_inputs 
    10061006 */ 
    10071007function wp_dashboard_rss_control( $widget_id, $form_inputs = array() ) { 
    10081008        if ( !$widget_options = get_option( 'dashboard_widget_options' ) )