WordPress.org

Make WordPress Core

Changes between Version 1 and Version 2 of Ticket #20246, comment 9


Ignore:
Timestamp:
09/03/12 20:52:45 (20 months ago)
Author:
SergeyBiryukov
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #20246, comment 9

    v1 v2  
    2626No video was displayed in the post. `var_dump()` showed that `$data->html` was a SimpleXMLElement object (like the one above). Looks like [20539] broke XML oEmbed responses, which is a regression. 
    2727 
    28 According to the php.net manual, we should cast the elements to strings (see example 6): [[BR]] 
    29 http://www.php.net/manual/en/simplexml.examples-basic.php 
     28According to the [http://www.php.net/manual/en/simplexml.examples-basic.php php.net manual], we should cast the elements to strings (see example 6): [[BR]] 
     29> To compare an element or attribute with a string or pass it into a function that requires a string, you must cast it to a string using `(string)`. Otherwise, PHP treats the element as an object. 
    3030 
    3131[attachment:20246.2.patch] does that.