CoreFiles by mySites.guru
postbox.js14 lines, 549 bytes, from wordpress-2.6.zip
Raw History Compare with 2.5.1
md5
8421d4a0813473667bac239989a2fc90
sha1
4bc3a0a980bffa972d3bc6e18e070ca53ccc11fe
sha256
30a203ebed0569c521fc1a3b0022a62f2a6620f4f3c8fbd310230933557f7b40
function add_postbox_toggles(page) {
	jQuery('.postbox h3').prepend('<a class="togbox">+</a> ');
	jQuery('.postbox h3').click( function() { jQuery(jQuery(this).parent().get(0)).toggleClass('closed'); save_postboxes_state(page); } );
}

function save_postboxes_state(page) {
	var closed = jQuery('.postbox').filter('.closed').map(function() { return this.id; }).get().join(',');
	jQuery.post(postboxL10n.requestFile, {
		action: 'closed-postboxes',
		closed: closed,
		closedpostboxesnonce: jQuery('#closedpostboxesnonce').val(),
		page: page
	});
}

The same content is in 16 releases, WordPress 2.5-RC1 to 2.6.5. See them all, or every version of this file.