WordPress.org

Make WordPress Core

Opened 2 years ago

Closed 2 years ago

#20322 closed defect (bug) (fixed)

viddler embed not working

Reported by: arena Owned by: nacin
Milestone: 3.4 Priority: normal
Severity: normal Version: 3.4
Component: Embeds Keywords: has-patch
Focuses: Cc:

Description

when having this in a post :

http://www.viddler.com/explore/BigAppleChannel/videos/113/

should display the video !

but nothing appears

Attachments (2)

wp-oembed-data2html-sanitition.diff (1.9 KB) - added by nacin 2 years ago.
Patch from mdawaffe.
20322.diff (1.7 KB) - added by nacin 2 years ago.
Smooth the edges of the initial patch. Always use the filter.

Download all attachments as: .zip

Change History (12)

comment:1 Ipstenu2 years ago

Doesn't work on my 3.3 install, but it works on my wordpress.com blog.

I get this error on 3.3

Warning: strpos() expects parameter 1 to be string, object given in /home/foobar/public_html/wp-includes/class-oembed.php on line 268

Catchable fatal error: Object of class stdClass could not be converted to string in /home/foobar/public_html/wp-includes/class-oembed.php on line 269

If I use [viddler id=8918af90]

I get [ERROR: An invalid Viddler shortcode format was used. Please check your code.]

I can reproduce it with Viddler's sample video: http://www.viddler.com/explore/cdevroe/videos/424/ (just to make sure it wasn't the vid itself)

ETA - If the video is the last line of content, it's a blank page on 3.4 - If there's there's anything below it, it shows the video URL.

Last edited 2 years ago by Ipstenu (previous) (diff)

comment:2 helenyhou2 years ago

Contrary to their docs, Viddler seems to actually return an object for the html value now, which is not in line with the oEmbed spec. Example

comment:3 nacin2 years ago

We've been discussing this internally on the security team list and had planned to make it public. Someone reached out to Viddler but apparently they have not acted on this.

Let's add some poka-yoke here to ensure we are always dealing with a scalar value. And then get Viddler to fix their broken endpoint.

Last edited 2 years ago by nacin (previous) (diff)

nacin2 years ago

Patch from mdawaffe.

comment:4 nacin2 years ago

  • Keywords has-patch added

comment:5 nacin2 years ago

  • Milestone changed from Awaiting Review to Future Release

comment:6 nacin2 years ago

  • Milestone changed from Future Release to 3.4

nacin2 years ago

Smooth the edges of the initial patch. Always use the filter.

comment:9 nacin2 years ago

  • Severity changed from major to normal

comment:10 nacin2 years ago

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

In [20539]:

Add sanity checks to WP_oEmbed::data2html() to ensure we are working with scalar values. Always use the filter. props mdawaffe, fixes #20322.

Note: See TracTickets for help on using tickets.