Attention Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Plugin API/Action Reference/in admin footer

The in_admin_footer action is triggered just after the <div id="footer"> tag of the admin-footer.php page at wp-admin/admin-footer.php. This position makes it a prime location for hooking javascript that fires on document.ready for the admin page. Also good for php functions targeted at customization of the admin footer.

    <?php add_action('in_admin_footer', 'foot_monger');
    function foot_monger () {  ?>
    //script adapted from:
    // http://codex.wordpress.org/Plugin_API/Action_Reference/quick_edit_custom_box
    <script type='text/javascript'>
    function quickEditSmiles() {
         var $ = jQuery;
         var _edit = inlineEditPost.edit;
              inlineEditPost.edit = function(id) {  
         var args = [].slice.call(arguments);
              _edit.apply(this, args);
         if (typeof(id) == 'object') { id = this.getId(id); }
              var editRow = jQuery('#edit-' + id),
         postRow = jQuery('#post-'+id),
                       smile = jQuery('.report-content', postRow).text();
                       jQuery( 'textarea[name="p_content"]' ).text(smile);
                             }; }
    jQuery(document).ready( function(){	
    if (inlineEditPost) {	quickEditSmiles(); } else {
    jQuery(quickEditSmiles);}   });	</script>
    // write some php here or just remake the footer and use die(); to finish the page etc. 
This page is marked as incomplete. You can help Codex by expanding it.