WordPress.org

Make WordPress Core

Opened 3 years ago

Last modified 3 years ago

#31689 new defect (bug)

Media player not working with 302 redirects

Reported by: hlashbrooke Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.1.1
Component: External Libraries Keywords:
Focuses: Cc:

Description

When calling the audio player using wp_audio_shortcode( array( 'src' => '/path/to/file' ) ); and the path in question is a 302 redirect to an actual audio file, the audio player cannot find or play the file.

A prime example of this is with Microsoft's OneDrive - a public link to a file stored with them looks like this: https://onedrive.live.com/download?resid=###. Going to that URL ends up in a 302 redirect to the actual file. While OneDrive may not be the best way to store and share media files, it is still a valid use case. Plus, this will affect any file storage where the file is accessed via a 302 redirect.

There are alternative audio players that can handle 302 redirected files, so it's not impossible to work around the issue.

For reference, this came up in a support ticket for one of my plugins - details here: https://wordpress.org/support/topic/direct-link-to-onedrive.

Change History (1)

#1 @wonderboymusic
3 years ago

  • Component changed from Media to External Libraries

This would probably have to be fixed here: https://github.com/johndyer/mediaelement

Note: See TracTickets for help on using tickets.