Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- jQuery.ajax( {
- url: Slug_API_Settings.root + 'wp/v2/users/',
- method: 'POST',
- beforeSend: function ( xhr ) {
- xhr.setRequestHeader( 'X-WP-Nonce', Slug_API_Settings.nonce );
- },
- data:{
- email: 'someone@somewhere.net',
- username: 'someone',
- password: Math.random().toString(36).substring(7)
- }
- } ).done( function ( response ) {
- console.log( response );
- } )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement