AHC and ESSL Wordpress Hosting Service

Vimeo Shortcode

This shortcode accesses Vimeo’s Simple API to get the public JSON feeds for a user’s videos using the endpoints for the user, groups, channels, albums, and single videos. By default it outputs a single iframe element for the first video in a set, and the thumbnails of the other videos in the set (if there is more than one) underneath, linked so they load the corresponding video into the iframe.

Using the Vimeo Shortcode

The shortcode uses the vimeo keyword, and can accept the following parameters:

id
required The id of the video/group/channel/album/user on vimeo
source
optional which one of video, group, channel, album or user you are requesting. This defaults to a single video (so the id parameter is treated as the id of a single video)
width
optional (default 640) The width of the video in pixels
height
optional (default 360) The height of the video in pixels
title
optional (default 0 – false) Whether to show the title on the video
byline
optional (default 0 – false) Whether to show the user’s byline on the video
portrait
optional (default 0 – false) Whether to show the user’s portrait on the video
colour
optional (default #ff0000 – red) The colour of the vimeo elements on screen (title, controls, etc.)
autoplay
optional (default 0 – false) Whether to start playing the video immediately, or wait for user input.

Formatting of output

The thumbnails are currently output at 160px wide, with a 10px right margin. This means that if you want a 3 column wall (when you are using both sidebars), set the video size to 500px x 281px. If you want a four column wall (when you are using just the site sidebar), set the video size to 670px x 377px.

© Copyright Leeds 2017