Changeset 38772
- Timestamp:
- 10/10/2016 10:41:26 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/js/post.js
r38637 r38772 106 106 * 107 107 * @param {string} html New HTML to be displayed in the content area of the postbox. 108 * 108 * 109 109 * @global 110 110 */ … … 500 500 } 501 501 502 var postID = $('#post_ID').val(); 503 var postLock = $('#active_post_lock').val(); 504 505 if ( ! postID || ! postLock ) { 506 return; 507 } 508 502 509 var data = { 503 510 action: 'wp-remove-post-lock', 504 511 _wpnonce: $('#_wpnonce').val(), 505 post_ID: $('#post_ID').val(),506 active_post_lock: $('#active_post_lock').val()512 post_ID: postID, 513 active_post_lock: postLock 507 514 }; 508 515 509 if ( window.FormData && window.navigator.sendBeacon) {516 if ( window.FormData && window.navigator.sendBeacon ) { 510 517 var formData = new window.FormData(); 511 518 512 $.each( data, function(key, value) {513 formData.append( key, value);519 $.each( data, function( key, value ) { 520 formData.append( key, value ); 514 521 }); 515 522 516 if ( window.navigator.sendBeacon(ajaxurl, formData)) {523 if ( window.navigator.sendBeacon( ajaxurl, formData ) ) { 517 524 return; 518 525 }
Note: See TracChangeset
for help on using the changeset viewer.