WordPress.org

Make WordPress Core

Ticket #18709: 18709.diff

File 18709.diff, 2.1 KB (added by jeremyfelt, 8 years ago)
  • src/wp-admin/network/user-new.php

     
    9999                        <td colspan="2"><?php _e( 'Username and password will be mailed to the above email address.' ) ?></td>
    100100                </tr>
    101101        </table>
     102        <?php
     103        //duplicate_hook
     104        do_action( 'user_new_form', 'add-new-user' );
     105        ?>
    102106        <?php wp_nonce_field( 'add-user', '_wpnonce_add-user' ) ?>
    103107        <?php submit_button( __('Add User'), 'primary', 'add-user' ); ?>
    104108        </form>
  • src/wp-admin/user-new.php

     
    310310        </tr>
    311311<?php } ?>
    312312</table>
     313<?php
     314/**
     315 * Fires at the end of the new user form.
     316 *
     317 * Passes a contextual string to make both types of new user forms
     318 * uniquely targetable. Contexts are 'add-existing-user' (Multisite),
     319 * and 'add-new-user' (single site and network admin).
     320 *
     321 * @since 3.7.0
     322 *
     323 * @param string A contextual string specifying which type of new user form the hook follows.
     324 */
     325do_action( 'user_new_form', 'add-existing-user' );
     326?>
    313327<?php submit_button( __( 'Add Existing User '), 'primary', 'adduser', true, array( 'id' => 'addusersub' ) ); ?>
    314328</form>
    315329<?php
     
    325339?>
    326340<form action="" method="post" name="createuser" id="createuser" class="validate"<?php do_action('user_new_form_tag');?>>
    327341<input name="action" type="hidden" value="createuser" />
    328 <?php wp_nonce_field( 'create-user', '_wpnonce_create-user' ) ?>
     342<?php wp_nonce_field( 'create-user', '_wpnonce_create-user' ); ?>
    329343<?php
    330344// Load up the passed data, else set to a default.
    331345foreach ( array( 'user_login' => 'login', 'first_name' => 'firstname', 'last_name' => 'lastname',
     
    412426        <?php } ?>
    413427</table>
    414428
     429<?php
     430//duplicate_hook
     431do_action( 'user_new_form', 'add-new-user' );
     432?>
     433
    415434<?php submit_button( __( 'Add New User '), 'primary', 'createuser', true, array( 'id' => 'createusersub' ) ); ?>
    416435
    417436</form>