File: vimeo.rb

package info (click to toggle)
tdiary-contrib 5.4.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 2,772 kB
  • sloc: ruby: 17,305; javascript: 8,263; lisp: 562; xml: 451; php: 61; sql: 40; makefile: 18
file content (14 lines) | stat: -rw-r--r-- 466 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#
# vimeo.rb - insert some services of vimeo.com
#
# Copyright (C) 2011, Kiwamu Okabe <kiwamu@debian.or.jp>.
# You can redistribute it and/or modify it under GPL2.
#

def vimeo( id )
	if feed? then
		return %Q|<a href="http://vimeo.com/#{id}">Link to vimeo ##{id}</a></p><p>|
	end

	%Q|<iframe src="http://player.vimeo.com/video/#{id}?title=0&amp;byline=0&amp;portrait=0" width="400" height="300" frameborder="0" webkitAllowFullScreen allowFullScreen></iframe>|
end