Hi Elliot,
Mostly my clients would ask for a separate video url or audio url for audio / video post format, and I think it’s kind of make sense because then everything looks organised.
I have managed to do that, but in a weird way.
First I thought it’s pretty simple because all I need to do is create a text field for the video embed code. Wrong… WordPress won’t render the thing as video / audio, only showing the embed code as text. I think the embed code should be in ‘the_content’ for WordPress to be able to render it as video / audio with player.
So I changed the field from text to WYSIWYG editor and it worked. But then obviously the buttons and the field size of the WYSIWYG doesn’t look make any sense at all. It should be just a plain simple text input box, I thought.
Then I decided to try find other ways to make it work so I changed again the WYSIWYG to plain input text box. When I got back to the front-end, the video is still there! I did also a test by changing the embed code, and it still works! I got exactly what I want now, the plain text box field for the video embed code and the embed code is properly rendered as video player by WordPress.
Why this happened and will it be a reliable solution for the idea?
Or is there a right way to do this? I got what I want to achieve, but i think that’s not really the way to do this.
I’ve tried also other way using the_content filter but then it got all mixed up because wordpress sees everything as content, not separating the video from text content.
Thanks