Embedded video doesn't show up
-
Hi Dcooney,
We have a lot of embedded you-tube videos, and they do not show up as embedded videos when the posts get loaded using the plugin, they just show up as a link. However, when we look at each individual post using permalink, the embedded video shows up in the post. Any ideas why?
Thanks,
Sia77
-
Ill have to look into this one. Im busy for the next day or so but will let u know.
Sounds great. Thanks.
Are you using a plugin to embed your videos?
I just tested the standard WordPress youtube video embed and it’s works as expected.No, we are not using any plugins. That’s strange.
Are you calling the_content() or the_excerpt()?
Do you have hooks or filters in place for the_content()?
It’s an ajax call. And the response is generated by:
$content = $content_post->post_content;
$content = apply_filters(‘the_content’, $content);
$content = str_replace(‘]]>’, ‘]]>’, $content);So I think I’m using the_content(). The thing is that I’m seeing the link to the video, but the link is not being rendered as a embeded video.
I took that third line out, just in case, and there was no difference.Its definitely something in the way the code is being rendered.
If you use<?php the_content(); ?>in the repeater template it works as expected.You are absolutely correct. This has something to do with how the_content() works Vs apply_filters(‘the_content’, $content), and how the latter doesn’t let WordPress do its magic.
Thanks for taking the time on this.
The topic ‘Embedded video doesn't show up’ is closed to new replies.