WordPress.org

Make WordPress Core

Ticket #11933: 11933.diff

File 11933.diff, 2.3 KB (added by sivel, 5 years ago)

Adds action to add/edit user and to edit post pages.

  • wp-admin/user-new.php

     
    168168        echo '<p>' . __( 'That person will be sent an email asking them to click a link confirming the invite. New users will then be sent an email with a randomly generated password and a login link.' ) . '</p>'; 
    169169} 
    170170?> 
    171 <form action="#add-new-user" method="post" name="adduser" id="adduser" class="add:users: validate"> 
     171<form action="#add-new-user" method="post" name="adduser" id="adduser" class="add:users: validate" <?php do_action('user_new_form_tag');?>> 
    172172<?php wp_nonce_field('add-user') ?> 
    173173<?php 
    174174//Load up the passed data, else set to a default. 
  • wp-admin/edit-form-advanced.php

     
    158158<?php if ( $message ) : ?> 
    159159<div id="message" class="updated"><p><?php echo $message; ?></p></div> 
    160160<?php endif; ?> 
    161 <form name="post" action="post.php" method="post" id="post"> 
     161<form name="post" action="post.php" method="post" id="post" <?php do_action('post_edit_form_tag'); ?>> 
    162162<?php wp_nonce_field($nonce_action); ?> 
    163163<input type="hidden" id="user-id" name="user_ID" value="<?php echo (int) $user_ID ?>" /> 
    164164<input type="hidden" id="hiddenaction" name="action" value="<?php echo esc_attr($form_action) ?>" /> 
  • wp-admin/user-edit.php

     
    165165<?php screen_icon(); ?> 
    166166<h2><?php echo esc_html( $title ); ?></h2> 
    167167 
    168 <form id="your-profile" action="<?php if ( IS_PROFILE_PAGE ) { echo admin_url('profile.php'); } else { echo admin_url('user-edit.php'); } ?>" method="post"> 
     168<form id="your-profile" action="<?php if ( IS_PROFILE_PAGE ) { echo admin_url('profile.php'); } else { echo admin_url('user-edit.php'); } ?>" method="post" <?php do_action('user_edit_form_tag'); ?>> 
    169169<?php wp_nonce_field('update-user_' . $user_id) ?> 
    170170<?php if ( $wp_http_referer ) : ?> 
    171171        <input type="hidden" name="wp_http_referer" value="<?php echo esc_url($wp_http_referer); ?>" />