WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #16031, comment 65


Ignore:
Timestamp:
10/21/2015 05:34:41 AM (5 years ago)
Author:
Veraxus
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #16031, comment 65

    initial v1  
    44
    55* Every admin screen handles actions ''outside'' of the `WP_List_Table` class, on its respective screen.
    6 * After hard-coded default actions are handled, a custom redirect is built by feeding the current URL through `add_query_arg()` as necessary. This ensures that duplicate actions aren't accidentally run by flushing the request data after it's handled.
     6* After hard-coded default actions are handled, a custom redirect is built by feeding the current URL through `add_query_arg()` as necessary. This ensures that duplicate actions aren't accidentally executed on refresh, since the redirect effectively flushes the request data after it's handled.
    77* `$wp_list_table->prepare_items()` is usually run after the aforementioned redirect (and after actions are caught and handled), meaning our request data will never reach it. It's also not executed consistently before or after actions are handled.
    88* When and where the redirect is handled by each screen sometimes varies wildly. But each time the hook needs to occur ''before'' the forced redirect occurs (which flushes our request data), but before `$wp_list_table->prepare_items()` is executed.