diff --git a/lightbox2.module b/lightbox2.module index 216c9f9bfd25c341d11ee86ceca2269824d3c1af..ad890b674fa6183a2b5bab61dd84e0bd46523498 100644 --- a/lightbox2.module +++ b/lightbox2.module @@ -642,6 +642,20 @@ function lightbox2_filter_tips($delta, $format, $long = FALSE) { return $output; } } + else if ($delta == 4) { + if (!$long) { + return t('Links to video content with \'rel="lightvideo"\' in the <a> tag will appear in a Lightbox when clicked on.'); + } + else { + $output = '
'. t('It\'s possible to show video content in the lightbox. In this case the "rel" attribute should be set to lightvideo
. It\'s not possible to group videos but it is possible to control the size of the lightbox by setting the "width" and "height" properties. The properties can be configured like lightvideo[width:300px; height: 200px;]
. The properties should all be of the format "property: value;" - note the closing semi-colon. If no properties are set, then the default width and height of 400px will be used. See below for more detailed examples.') .'
'. t('Basic example:') .'
';
+ $output .= t('<a href="http://video.google.com/videoplay?docid=1811233136844420765" rel="lightvideo">Google video example - default size</a>
') .'
'. t('Controlling lightbox size example:') .'
';
+ $output .= t('<a href="http://video.google.com/videoplay?docid=1811233136844420765" rel="lightvideo[width:400px; height:300px;]">Google video example - custom size</a>
') .'
'. t('Supported video formats include asx, wmv, mov and swf. A number of online video providers are also supported, including YouTube and Google Video. For a full list of the current supported video providers please see the documentation on drupal.org.') .'
'; + return $output; + } + } } /** @@ -654,7 +668,8 @@ function lightbox2_filter($op, $delta = 0, $format = -1, $text = '') { 0 => t('Lightbox filter'), 1 => t('Lightbox G2 filter'), 2 => t('Lightbox slideshow filter'), - 3 => t('Lightbox iframe filter') + 3 => t('Lightbox iframe filter'), + 4 => t('Lightbox video filter'), ); case 'description': @@ -670,6 +685,9 @@ function lightbox2_filter($op, $delta = 0, $format = -1, $text = '') { else if ($delta == 3) { return t('Links to HTML content with \'rel="lightframe"\' in the <a> tag will appear in a Lightbox when clicked on.'); } + else if ($delta == 4) { + return t('Links to video content with \'rel="lightvideo"\' in the <a> tag will appear in a Lightbox when clicked on.'); + } case 'process': if ($delta == 1) {