forked from lackac/clippy
-
Notifications
You must be signed in to change notification settings - Fork 2
/
server.rb
45 lines (39 loc) · 2.12 KB
/
server.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
require 'rubygems'
require 'sinatra'
set :public, File.dirname(__FILE__)
get '/' do
%q{
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test</title>
</head>
<body>
<script type='text/javascript'>
function test_1_call_back() { alert('callBack 1'); }
function test_2_call_back() { alert('callBack 2'); }
</script>
<object height="14" width="110" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" id='test1'>
<param value="/build/clippy.swf" name="movie"/>
<param value="always" name="allowScriptAccess"/>
<param value="high" name="quality"/>
<param value="noscale" name="scale"/>
<param value="id=test_1&copied=copied©to=copyToClipboard" name="FlashVars"/>
<param value="#FFFFFF" name="bgcolor"/>
<embed height="14" width="110" bgcolor="#FFFFFF" flashvars="id=test_1&copied=copied!©to=copyToClipboard" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" allowscriptaccess="always" quality="high" name="clippy" src="/build/clippy.swf"/>
</object>
<textarea id="test_1">this is test 1</textarea>
<object height="14" width="110" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" id='test2'>
<param value="/build/clippy.swf" name="movie"/>
<param value="always" name="allowScriptAccess"/>
<param value="high" name="quality"/>
<param value="noscale" name="scale"/>
<param value="id=test_2&copied=copied©to=copyToClipboard&callBack=test_2_call_back" name="FlashVars"/>
<param value="#FFFFFF" name="bgcolor"/>
<embed height="14" width="110" bgcolor="#FFFFFF" flashvars="id=test_2&copied=copied!©to=copyToClipboard&callBack=test_2_call_back" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" allowscriptaccess="always" quality="high" name="clippy" src="/build/clippy.swf"/>
</object>
<div id="test_2">this is test 2</div>
</body>
</html>
}
end