rate5me_grs 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/rate5me_grs.rb +24 -0
- metadata +54 -0
data/lib/rate5me_grs.rb
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
require 'nokogiri'
|
|
2
|
+
require 'open-uri'
|
|
3
|
+
|
|
4
|
+
class Rate5meGrs
|
|
5
|
+
|
|
6
|
+
def self.get_widget(id)
|
|
7
|
+
connection = Connection.new(id)
|
|
8
|
+
return connection.get_html
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
end
|
|
12
|
+
|
|
13
|
+
class Rate5meGrs::Connection
|
|
14
|
+
|
|
15
|
+
def initialize(id)
|
|
16
|
+
@id = id
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
def get_html
|
|
20
|
+
html = Nokogiri::HTML(open("http://rate5.me/widgets/#{@id}/widget.html"))
|
|
21
|
+
return html.to_html
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: rate5me_grs
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
prerelease:
|
|
5
|
+
version: 0.0.0
|
|
6
|
+
platform: ruby
|
|
7
|
+
authors:
|
|
8
|
+
- Nick Bohlen
|
|
9
|
+
autorequire:
|
|
10
|
+
bindir: bin
|
|
11
|
+
cert_chain: []
|
|
12
|
+
|
|
13
|
+
date: 2012-07-27 00:00:00 Z
|
|
14
|
+
dependencies: []
|
|
15
|
+
|
|
16
|
+
description: adds rich snippets information from your rate5.me project to your website.
|
|
17
|
+
email: mail@bohlen-design.de
|
|
18
|
+
executables: []
|
|
19
|
+
|
|
20
|
+
extensions: []
|
|
21
|
+
|
|
22
|
+
extra_rdoc_files: []
|
|
23
|
+
|
|
24
|
+
files:
|
|
25
|
+
- lib/rate5me_grs.rb
|
|
26
|
+
homepage: http://rubygems.org/gems/rate5me_grs
|
|
27
|
+
licenses: []
|
|
28
|
+
|
|
29
|
+
post_install_message:
|
|
30
|
+
rdoc_options: []
|
|
31
|
+
|
|
32
|
+
require_paths:
|
|
33
|
+
- lib
|
|
34
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
35
|
+
none: false
|
|
36
|
+
requirements:
|
|
37
|
+
- - ">="
|
|
38
|
+
- !ruby/object:Gem::Version
|
|
39
|
+
version: "0"
|
|
40
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
41
|
+
none: false
|
|
42
|
+
requirements:
|
|
43
|
+
- - ">="
|
|
44
|
+
- !ruby/object:Gem::Version
|
|
45
|
+
version: "0"
|
|
46
|
+
requirements: []
|
|
47
|
+
|
|
48
|
+
rubyforge_project:
|
|
49
|
+
rubygems_version: 1.8.24
|
|
50
|
+
signing_key:
|
|
51
|
+
specification_version: 3
|
|
52
|
+
summary: adds rich snippets information from your rate5.me project to your website.
|
|
53
|
+
test_files: []
|
|
54
|
+
|