I created a custom display form for a list. This list have a media field column. And in my custom display form I want to be able to play a video that I have uploaded to this list.

When I upload a video to this media field column, the video is uploaded to an Asset Library. And when I open the list item with my custom edit form, it only shows the url of the video.

When I open the item with the default display form, the video player appears normally, but in my custom form it only shows the url.

The default display form uses ListFormWebPart to display items. But custom display form uses an xsl template.

Here is what it looks like;

<xsl:template name="dvt_1.rowview">
                <table border="0" cellspacing="0" width="100%">
                        <td width="500px" valign="top" class="ms-formbody">
                            <xsl:value-of select="@Video"/>
                    <xsl:if test="$dvt_1_automode = '1'" ddwrt:cf_ignore="1">
                            <td colspan="99" class="ms-vb">
                                <span ddwrt:amkeyfield="ID" ddwrt:amkeyvalue="ddwrt:EscapeDelims(string(@ID))" ddwrt:ammode="view"></span>

This code only show the url of the video. Do you have any idea how to play video on custom display forms?

4 Answers 4


Why don't you add a Content editor web part on dispform.aspx and try adding the video play (code) there instead?

You can always add a Web Part to the list forms.

  • I tried, but the problem is; I have other columns than the Video column. the page is loaded with querystring which brings the id of the list item. Everytime it is a different item, so the video will change when the item is changed. Does content editor support this somehow?
    – yur
    Commented Jan 18, 2012 at 13:08
  • Yes, you can use jQuery Script or Javascript to pass the parameters to the video as well. look at this sample example geekswithblogs.net/SoYouKnow/archive/2011/04/06/… Commented Jan 18, 2012 at 13:55

Free Styler's option would work, the only hang up might be that your video URL is stored in the item's data, and you can't connect a CEWP to a display form to extract the data.

You could use your XSL in your display form to write the embed code for a player like Flowplayer (http://flowplayer.org/) and pass the URL in from the data.


this might help:


but I would do it like 'Free Styler' with a content web part.


You should be able to take your custom display form edit it in SPD and create a webpartzone for the area you would like to play the video in. Open the page in SharePoint and then add the media element webpart use the initialization parameter to give it the address of your video on load.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.