/[drupal]/contributions/modules/emfield/contrib/video_cck/providers/jumpcut.inc
ViewVC logotype

Contents of /contributions/modules/emfield/contrib/video_cck/providers/jumpcut.inc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (show annotations) (download) (as text)
Mon May 12 04:10:54 2008 UTC (18 months, 2 weeks ago) by alexua
Branch: MAIN
CVS Tags: DRUPAL-5--1-3, HEAD
Changes since 1.3: +3 -3 lines
File MIME type: text/x-php
Corrected all errors registered by Coder module in preperation for D6 port
1 <?php
2 // $Id: jumpcut.inc,v 1.3 2007/09/06 22:18:25 aaron Exp $
3
4 define('VIDEO_CCK_JUMPCUT_MAIN_URL', 'http://jumpcut.com/');
5
6 function video_cck_jumpcut_info() {
7 $name = t('JumpCut');
8 $features = array(
9 array(t('Autoplay'), t('No'), ''),
10 array(t('RSS Attachment'), t('No'), ''),
11 array(t('Thumbnails'), t('No'), ''),
12 );
13 return array(
14 'provider' => 'jumpcut',
15 'name' => $name,
16 'url' => VIDEO_CCK_JUMPCUT_MAIN_URL,
17 'settings_description' => t('These settings specifically affect videos displayed from !provider.', array('!provider' => l($name, VIDEO_CCK_JUMPCUT_MAIN_URL, array('target' => '_blank')))),
18 'supported_features' => $features,
19 );
20 }
21
22 function video_cck_jumpcut_settings() {
23 $form = array();
24 return $form;
25 }
26
27 function video_cck_jumpcut_extract($embed) {
28 return array(
29 '@jumpcut\.com/view\?id=(.*)@i',
30 '@jumpcut\.com/view\?id=([^\&]*)\&@i',
31 );
32 }
33
34 function video_cck_jumpcut_video_link($video_code) {
35 return 'http://jumpcut.com/view?id='. $video_code;
36 }
37
38 function theme_video_cck_jumpcut_flash($embed, $width, $height) {
39 if ($embed) {
40 $output .= '<embed src="http://jumpcut.com/media/flash/jump.swf?id='. $embed .'&asset_type=movie&asset_id='. $embed .'&eb=1" width="'. $width .'" height="'. $height .'" type="application/x-shockwave-flash"></embed>';
41 }
42 return $output;
43 }
44
45 function video_cck_jumpcut_thumbnail($field, $item, $formatter, $node, $width, $height) {
46 return '';
47 }
48
49 function video_cck_jumpcut_video($embed, $width, $height, $field, $item) {
50 $output = theme('video_cck_jumpcut_flash', $embed, $width, $height);
51 return $output;
52 }
53
54 function video_cck_jumpcut_preview($embed, $width, $height, $field, $item) {
55 $output = theme('video_cck_jumpcut_flash', $embed, $width, $height);
56 return $output;
57 }
58

  ViewVC Help
Powered by ViewVC 1.1.2