From 527c9dca0b5d71513adff8c7f8df6b88315bc6cf Mon Sep 17 00:00:00 2001 From: brettp Date: Wed, 14 Apr 2010 22:43:47 +0000 Subject: Added vimeo support to ECML. git-svn-id: http://code.elgg.org/elgg/trunk@5736 36083f99-b078-4883-b0ff-0f9b5a30f544 --- mod/ecml/start.php | 2 +- mod/ecml/views/default/ecml/keywords/vimeo.php | 54 ++++++++++++++++++++++++++ 2 files changed, 55 insertions(+), 1 deletion(-) create mode 100644 mod/ecml/views/default/ecml/keywords/vimeo.php (limited to 'mod') diff --git a/mod/ecml/start.php b/mod/ecml/start.php index 6bf1a565d..51082e9c6 100644 --- a/mod/ecml/start.php +++ b/mod/ecml/start.php @@ -128,7 +128,7 @@ function ecml_parse_view($hook, $entity_type, $return_value, $params) { * @return unknown_type */ function ecml_keyword_hook($hook, $entity_type, $return_value, $params) { - $keywords = array('youtube', 'slideshare'); + $keywords = array('youtube', 'slideshare', 'vimeo'); foreach ($keywords as $keyword) { $return_value[$keyword] = array( diff --git a/mod/ecml/views/default/ecml/keywords/vimeo.php b/mod/ecml/views/default/ecml/keywords/vimeo.php new file mode 100644 index 000000000..6ca1294a8 --- /dev/null +++ b/mod/ecml/views/default/ecml/keywords/vimeo.php @@ -0,0 +1,54 @@ + $vid, 'server' => 'vimeo.com'); + + $params = array( + 'show_title' => 1, + 'show_byline' => 1, + 'show_portrait' => 0, + 'color' => '', + 'fullscreen' => 1 + ); + + foreach ($params as $param => $default) { + $query[$param] = (isset($vars[$param])) ? $vars[$param] : $default; + } + + $query_str = http_build_query($query); + $movie_url .= $query_str; + + echo " + + + + + + + + "; +} \ No newline at end of file -- cgit v1.2.3