Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #23149, comment 19


Ignore:
Timestamp:
01/11/2014 07:23:34 PM (11 years ago)
Author:
Otto42
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #23149, comment 19

    initial v1  
    1 @adamsilverstein: The shortcode function won't work for testing here because you're not in a normal Loop and so there is no global $post context setup. The shortcode expects there to be a $post because it uses the $postmeta to do caching of the oembed result. This is to prevent it from retrieving the info from the remote URL every time. Additionally, you have to use a real working YouTube URL for it to actually get anything back, a fake URL won't have valid response data.
     1@adamsilverstein: The shortcode function won't work for testing here because you're not in a normal Loop and so there is no global $post context setup. The shortcode expects there to be a $post because it uses the post_meta to do caching of the oembed result. This is to prevent it from retrieving the info from the remote URL every time. Additionally, you have to use a real working YouTube URL for it to actually get anything back, a fake URL won't have valid response data.
    22
    33