Make WordPress Core

Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#22465 closed defect (bug) (fixed)

Media uploader throws PHP notice if $_REQUEST[ 'post_id' ] is not set

Reported by: ldebrouwer's profile ldebrouwer Owned by: nacin's profile nacin
Milestone: 3.5 Priority: normal
Severity: trivial Version: 3.5
Component: Upload Keywords: has-patch commit
Focuses: Cc:

Description

When including the media uploader in the backend without setting $_REQUEST[ 'post_id' ] this will result in a PHP notice on line 1380 in /wp-admin/includes/media.php.

Attachments (1)

notice-be-gone.diff (1.3 KB) - added by ldebrouwer 12 years ago.
Fixed, plus it also avoids two similar instances of the same notice.

Download all attachments as: .zip

Change History (4)

@ldebrouwer
12 years ago

Fixed, plus it also avoids two similar instances of the same notice.

#1 @nacin
12 years ago

  • Keywords commit added; needs-testing removed
  • Milestone changed from Awaiting Review to 3.5

#2 @nacin
12 years ago

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

In 22628:

Prevent notices when post_id is not passed to the old media upload forms. props ldebrouwer. fixes #22465.

#3 @SergeyBiryukov
12 years ago

#22098 was marked as a duplicate.

Note: See TracTickets for help on using tickets.