/** * Sets the media for the post. * * @return void * @access public * @since 1.0.0 */ public function set_media() { if (isset($this->args['meta_key'])) { $url = get_post_meta(get_the_ID(), $this->args['meta_key'], true); $this->media = do_shortcode("[{$this->type} src='{$url}']"); } parent::set_media(); }
/** * Wrapper function for the Hybrid_Media_Grabber class. Returns the HTML output for the found media. * * @since 1.6.0 * @access public * @param array * @return string */ function hybrid_media_grabber($args = array()) { $media = new Hybrid_Media_Grabber($args); return $media->get_media(); }