Giter Site home page Giter Site logo

jwplayer's Introduction

This module provides a simple and light-weight field formatter for all filefields. When applied to filefields containing .flv or .mp4 video file it will use the JWPlayer flash video player to embed the video directly onto the page.

-------------------------------------------------------------------------------
Requirements:
-------------------------------------------------------------------------------

This module requires the jwplayer.js, and player.swf files from the JWPLayer project. Available from http://www.longtailvideo.com/players/

Download the files and unzip them then move/rename the resulting directory to sites/all/modules/filefield_jwplayer/jwplayer/.


-------------------------------------------------------------------------------
Usage:
-------------------------------------------------------------------------------

Once enabled you will be able to apply the new formatter to any filefield by editing the display settings for the associated content type.

-------------------------------------------------------------------------------
For Developers/Themers:
-------------------------------------------------------------------------------

The module exposes a single hook for developers. hook_filefield_jwplayer_config_alter(&$config) which receives an associative array that will eventually be used for configuring and embedding the jwplayer. For more information about possible values for this $config array see the jwplayer documentation, specifically information related to the JW Embedder. http://www.longtailvideo.com/support/jw-player/jw-player-for-flash-v5

Example:

function mymodule_filefield_jwplayer_config_alter(&$config) {
  // Add the quality monitor 2 plugin.
  $config['plugins'] = 'qualitymonitor-2';
  // Add a poster image to use when the player is embedded on the page but
  // before playback has started.
  $config['image'] = 'http://example.com/image.png';
}

Themers can also modify the $config options by overriding theme_filefield_jwplayer_formatter_jwplayer() and adding their own changes.

-------------------------------------------------------------------------------
Credits:
-------------------------------------------------------------------------------
Initial development by Lullabot: [email protected]

jwplayer's People

Contributors

eojthebrave avatar

Watchers

 avatar

Forkers

agiza

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.