WordPress.org

Make WordPress Core

Opened 7 years ago

Closed 7 years ago

#8135 closed defect (bug) (fixed)

'Delete' on edit pages bottom dropdown doesnt work

Reported by: DD32 Owned by:
Milestone: 2.7 Priority: normal
Severity: normal Version: 2.7
Component: Administration Keywords: has-patch
Focuses: Cc:

Description

Attempting to delete a page by selecting 'Delete' on the bottom form fails (On the Edit page listing)

Attachments (1)

8135.diff (490 bytes) - added by DD32 7 years ago.

Download all attachments as: .zip

Change History (10)

@DD327 years ago

comment:1 @DD327 years ago

  • Keywords has-patch added; needs-patch removed

comment:2 @ryan7 years ago

I think we need to check for doaction or doaction2 like edit.php does.

comment:3 @ryan7 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [9603]) Fix delete bulk op at end of pages list. Props DD32. fixes #8135

comment:4 follow-up: @DD327 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

I think we need to check for doaction or doaction2 like edit.php does.

Then that check needs to go higher in the page; Preferably on this line:

if ( isset($_GET['action']) && ( -1 != $_GET['action'] || -1 != $_GET['action2'] ) ) { 

I missed the fact that that line hadnt been set to check for action2 not being set

comment:5 @azaozz7 years ago

(In [9607]) Add check for bulk-edit when deleting posts/pages, see #8135

comment:6 in reply to: ↑ 4 @azaozz7 years ago

Replying to DD32:

Then that check needs to go higher in the page; Preferably on this line:
...
I missed the fact that that line hadnt been set to check for action2 not being set

Both 'action' and 'action2' are selects in the same form, so when one is set, the other should be set too when the form is submitted.

comment:7 @DD327 years ago

Both 'action' and 'action2' are selects in the same form, so when one is set, the other should be set too when the form is submitted.

Thats true, In which case, My initial patch should've been OK since 'action' is checked for on a line above (line 13), Its pointless checking for the items being set at that point, as it should only enter that code block if either of them are set.

comment:8 @azaozz7 years ago

Yes, but this form has several submit buttons, so selecting 'delete' and clicking the Filter button would delete any selected posts too... Not an expected behaviour.

comment:9 @ryan7 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed
Note: See TracTickets for help on using tickets.