WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/12/2015 02:27:50 AM (5 years ago)
Author:
wonderboymusic
Message:

When clicking "Show More Comments" in the Comments meta box on the Edit Post screen, change the click behavior to call a new class method on commentsBox, ->load(), that resets st (cool name) to the number of visible <tr>s before calling ->get(). This will account for spam'd and trash'd comments when returning comments at the proper offset.

Props utkarshpatel.
Fixes #33829.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/meta-boxes.php

    r33686 r34069  
    691691
    692692        ?>
    693         <p class="hide-if-no-js" id="show-comments"><a href="#commentstatusdiv" onclick="commentsBox.get(<?php echo $total; ?>);return false;"><?php _e('Show comments'); ?></a> <span class="spinner"></span></p>
     693        <p class="hide-if-no-js" id="show-comments"><a href="#commentstatusdiv" onclick="commentsBox.load(<?php echo $total; ?>);return false;"><?php _e('Show comments'); ?></a> <span class="spinner"></span></p>
    694694        <?php
    695695    }
Note: See TracChangeset for help on using the changeset viewer.