Kentico CMS 6.0 Developer's Guide

Inserting audio/video

Inserting audio/video

Previous topic Next topic Mail us feedback on this topic!  

Inserting audio/video

Previous topic Next topic JavaScript is required for the print function Mail us feedback on this topic!  

devguide_clip0880

 

When inserting both audio and video, the following properties can be set:

 

URL - URL of the attached audio/video file.

Width, Height - the width and height of the media player; 300x200px is used by default.

Aspect ratio can be locked (UnlockRatio), which makes the second dimension recalculated automatically when you change one dimension, while the ratio between the two dimensions is kept.

If unlocked (LockRatio), dimensions can be entered manually into both fields, without the ratio being kept.

You can also reload the default dimensions using the Reset size (Undo) icon.

Autoplay - indicates if playback starts automatically when the page is loaded.

Loop - indicates if playback is performed repeatedly in a loop.

Show controls - indicates if playback controls (play, stop, fast forward, ...) are displayed. In some browsers, the controls may not be displayed if the player size is too small even if this option is enabled.

 

Audio and video is inserted into the output code as the Media inline control. The output code looks like the following code sample:

 

<object codetype="CMSInlineControl" height="200" type="Media" width="300">

<param name="ext" value=".avi" />

<param name="cms_type" value="audiovideo" />

<param name="url" value="~/getattachment/Sample.avi.aspx" />

</object>

 

In the WYSIWYG editor, the player is not displayed. Instead, only a box with the audio/video icon can be seen, giving information about the size of the player on the live site:

 

devguide_clip0881

 

And this is how it looks on the live site:

 

devguide_clip0885