Inserting schema.org markup for self-hosted videos

Hi. I am using x_video_player to present short self-hosted videos. I can’t seem to make any of the schema.org plugins to work with me and the video player. How can I insert the appropriate schema markup into the x_video_player shortcode?

Thank you.

Hello @SwissArmyKnife,

Thanks for writing in!

Regretfully the classic video shortcode do not have any support to schema. What you can do is to create a custom schema content for the video and insert the video shortcode like this:

<div itemprop="video" itemscope itemtype="http://schema.org/VideoObject">
    <h2>Video: <span itemprop="name">Title</span></h2>
    <meta itemprop="duration" content="T1M33S" />
    <meta itemprop="thumbnailUrl" content="thumbnail.jpg" />
    <meta itemprop="contentURL" content="http://www.example.com/video123.mp4" />
    <meta itemprop="embedURL" content="http://www.example.com/videoplayer.swf?video=123" />
    <meta itemprop="uploadDate" content="2017-23-05T08:00:00+08:00" />
    <meta itemprop="height" content="400" />
    <meta itemprop="width" content="400" />
    
    [x_video_player shortcode]

    <span itemprop="description">Video description</span>
</div>

For reference:

Hope this helps.

Thank you. I will try this over the weekend.

You are most welcome. :slight_smile:

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.