[wp-trac] [WordPress Trac] #44231: XML oembed discovery is not implemented correctly

WordPress Trac noreply at wordpress.org
Mon May 28 15:05:04 UTC 2018

#44231: XML oembed discovery is not implemented correctly
 Reporter:  rivalitaet    |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Embeds        |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:

Comment (by rivalitaet):

 Well, there are a couple of options:

 - WordPress should not put any format on a discovered endpoint, since the
 format is already set via the `type` parameter in HTML input. This might
 be difficult to implement, since currently an endpoint is only a string
 (with no information about the needed format).
 - As you pointed out, WordPress should not put the `json` format on a xml
 request. To not break any existing (wrong) implementations, we could also
 continue to send a request with each format, but try `xml` first for XML
 - WordPress could try to parse results in both of the formats: JSON
 parsing always fails for XML documents so this would be easy to implement.

 Especially the second and/or third option seem simple to do.

 If wanted, I could also provide a patch for this. You'd have to be a bit
 patient a bit with me though, I have no experience in using the WordPress
 trac system so far.

Ticket URL: <https://core.trac.wordpress.org/ticket/44231#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list