cyx-scraper 0.3.1 → 0.4.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/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.1
1
+ 0.4.0
data/lib/scraper.rb CHANGED
@@ -5,9 +5,10 @@ module Scraper
5
5
  autoload :Article, 'scraper/article'
6
6
  autoload :Youtube, 'scraper/youtube'
7
7
  autoload :Vimeo, 'scraper/vimeo'
8
+ autoload :Flickr, 'scraper/flickr'
8
9
  autoload :Modules, 'scraper/modules'
9
10
 
10
- HANDLERS = [ :Youtube, :Vimeo, :Article ]
11
+ HANDLERS = [ :Youtube, :Vimeo, :Flickr, :Article ]
11
12
  end
12
13
 
13
14
  def Scraper( args = {} )
@@ -0,0 +1,70 @@
1
+ # Copyright (c) 2009 [Cyril David]
2
+ #
3
+ # Permission is hereby granted, free of charge, to any person obtaining
4
+ # a copy of this software and associated documentation files (the
5
+ # "Software"), to deal in the Software without restriction, including
6
+ # without limitation the rights to use, copy, modify, merge, publish,
7
+ # distribute, sublicense, and/or sell copies of the Software, and to
8
+ # permit persons to whom the Software is furnished to do so, subject to
9
+ # the following conditions:
10
+ #
11
+ # The above copyright notice and this permission notice shall be
12
+ # included in all copies or substantial portions of the Software.
13
+ #
14
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21
+
22
+ require 'uri'
23
+
24
+ module Scraper
25
+ class Flickr
26
+ @@config = {
27
+ :valid_host_name => /\A([a-z]+\.)?flickr\.com\z/,
28
+ :photo_path_matcher => /\/photos\/[a-zA-Z0-9\@]+(\/([0-9]+))?\/?/,
29
+ :title_selector => 'h1',
30
+ :description_selector => '.photoDescription',
31
+ }
32
+
33
+ include Modules::Web::MetaData
34
+
35
+ def self.=~( args )
36
+ return false unless args[:url]
37
+
38
+ uri = URI.parse(args[:url])
39
+
40
+ if valid_host?(uri.host) and valid_path?(uri.path)
41
+ return new(args)
42
+ end
43
+ end
44
+
45
+ def self.valid_host?( host_name )
46
+ host_name.match(config[:valid_host_name])
47
+ end
48
+
49
+ def self.valid_path?( path )
50
+ path.match(config[:photo_path_matcher])
51
+ end
52
+
53
+ def initialize( args = {} )
54
+ @uri = URI.parse(args[:url])
55
+ end
56
+
57
+ def photostream?
58
+ matches = @uri.path.match(config[:photo_path_matcher])
59
+ matches[1].nil?
60
+ end
61
+
62
+ def thumbnail
63
+ if photostream?
64
+ doc.search('img.pc_img').first.attribute('src').to_s
65
+ else
66
+ doc.search('link[rel=image_src]').first.attribute('href').to_s
67
+ end
68
+ end
69
+ end
70
+ end
@@ -1,6 +1,3 @@
1
- require 'nokogiri'
2
- require 'open-uri'
3
-
4
1
  module Scraper
5
2
  module Modules
6
3
  module Video
@@ -21,37 +18,9 @@ module Scraper
21
18
  end
22
19
 
23
20
  module Common
24
- def self.included( base )
25
- base.cattr_accessor :config
26
- end
27
-
28
- def title
29
- @title ||= doc.search(config[:title_selector]).first.content
30
- end
31
-
32
- def description
33
- return @description if @description
34
-
35
- html = doc.search(config[:description_selector]).first.inner_html
36
- @description = dom(html.gsub(/<br\/?>/, ' ')).content.strip
37
- end
38
-
39
21
  def video_id
40
22
  @video_id
41
23
  end
42
-
43
- protected
44
- def dom( html )
45
- Nokogiri::HTML( html )
46
- end
47
-
48
- def uri
49
- @uri.scheme + '://' + @uri.host + @uri.request_uri
50
- end
51
-
52
- def doc
53
- @doc ||= dom( Modules::Web.open( uri ).read )
54
- end
55
24
  end
56
25
  end
57
26
  end
@@ -1,9 +1,48 @@
1
+ require 'nokogiri'
2
+ require 'open-uri'
3
+
1
4
  module Scraper
2
5
  module Modules
3
6
  module Web
4
7
  def self.open( *args )
5
8
  Kernel.open( *args )
6
9
  end
10
+
11
+ module MetaData
12
+ def self.included( base )
13
+ base.cattr_accessor :config
14
+ end
15
+
16
+ def title
17
+ @title ||= doc.search(config[:title_selector]).first.content.strip
18
+ end
19
+
20
+ def description
21
+ return @description if @description
22
+
23
+ if element = doc.search(config[:description_selector]).first
24
+ html = element.inner_html
25
+ html.gsub!(/<br\/?>/u, ' ')
26
+ html.gsub!("\302\240", ' ')
27
+ @description = dom(html).content.strip
28
+ else
29
+ @description = ''
30
+ end
31
+ end
32
+
33
+ protected
34
+ def dom( html )
35
+ Nokogiri::HTML( html )
36
+ end
37
+
38
+ def uri
39
+ @uri.scheme + '://' + @uri.host + @uri.request_uri
40
+ end
41
+
42
+ def doc
43
+ @doc ||= dom( Modules::Web.open( uri ).read )
44
+ end
45
+ end
7
46
  end
8
47
  end
9
48
  end
data/lib/scraper/vimeo.rb CHANGED
@@ -18,6 +18,7 @@ module Scraper
18
18
 
19
19
  extend Modules::Video::HostNameMatching
20
20
  include Modules::Video::Common
21
+ include Modules::Web::MetaData
21
22
 
22
23
  def initialize( args = {} )
23
24
  @uri = URI.parse(args[:url])
@@ -35,8 +35,9 @@ module Scraper
35
35
  :mime_type => 'application/x-shockwave-flash'
36
36
  }
37
37
 
38
- extend Modules::Video::HostNameMatching
38
+ extend Modules::Video::HostNameMatching
39
39
  include Modules::Video::Common
40
+ include Modules::Web::MetaData
40
41
 
41
42
  def initialize( args = {} )
42
43
  @uri = URI.parse(args[:url])
data/scraper.gemspec CHANGED
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{scraper}
5
- s.version = "0.3.1"
5
+ s.version = "0.4.0"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Cyril David"]
9
- s.date = %q{2009-07-31}
9
+ s.date = %q{2009-08-01}
10
10
  s.email = %q{cyx.ucron@gmail.com}
11
11
  s.extra_rdoc_files = [
12
12
  "LICENSE",
@@ -21,6 +21,7 @@ Gem::Specification.new do |s|
21
21
  "VERSION",
22
22
  "lib/scraper.rb",
23
23
  "lib/scraper/article.rb",
24
+ "lib/scraper/flickr.rb",
24
25
  "lib/scraper/modules.rb",
25
26
  "lib/scraper/modules/video.rb",
26
27
  "lib/scraper/modules/web.rb",
@@ -31,8 +32,11 @@ Gem::Specification.new do |s|
31
32
  "test/fixtures/5826468.html",
32
33
  "test/fixtures/dLO2s7SDHJo.html",
33
34
  "test/fixtures/non-article.html",
35
+ "test/fixtures/photostream.html",
34
36
  "test/fixtures/scraped.html",
37
+ "test/fixtures/show_photo.html",
35
38
  "test/fixtures/unwebbable.html",
39
+ "test/flickr_test.rb",
36
40
  "test/scraper_test.rb",
37
41
  "test/test_helper.rb",
38
42
  "test/vimeo_test.rb",
@@ -46,6 +50,7 @@ Gem::Specification.new do |s|
46
50
  s.summary = %q{TODO}
47
51
  s.test_files = [
48
52
  "test/article_test.rb",
53
+ "test/flickr_test.rb",
49
54
  "test/scraper_test.rb",
50
55
  "test/test_helper.rb",
51
56
  "test/vimeo_test.rb",
@@ -0,0 +1,834 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2
+
3
+ <html>
4
+ <head>
5
+ <title>Flickr: David Lazar's Photostream</title>
6
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
7
+ <meta name="keywords" content="photography, digital photography, cameraphones, camera, hobby photography, photo, digital camera, compactflash, smartmedia, cameras, canon, nikon, olympus, fujifilm, video">
8
+ <meta name="description" content="Flickr is almost certainly the best online photo management and sharing application in the world. Show off your favorite photos and videos to the world, securely and privately show content to your friends and family, or blog the photos and videos you take with a cameraphone.">
9
+ <meta http-equiv="imagetoolbar" content="no">
10
+ <meta name="title" content="Flickr: David Lazar's Photostream" />
11
+ <meta name="medium" content="image" />
12
+ <link rel="image_src" href="" />
13
+ <meta name="viewport" content="width=820">
14
+
15
+
16
+
17
+
18
+ <link type="text/css" rel="stylesheet" href="http://l.yimg.com/g/css/c_fold_main.css.v75456.64777.74571.14">
19
+
20
+
21
+ <link rel="alternate" type="application/atom+xml" title="Flickr: David Lazar's Photostream Atom feed" href="http://api.flickr.com/services/feeds/photos_public.gne?id=80186783@N00&amp;lang=en-us&amp;format=atom">
22
+ <link rel="alternate" type="application/rss+xml" title="Flickr: David Lazar's Photostream RSS feed" href="http://api.flickr.com/services/feeds/photos_public.gne?id=80186783@N00&amp;lang=en-us&amp;format=rss_200">
23
+
24
+ <link rel="shortcut icon" type="image/ico" href="/favicon.ico">
25
+
26
+ <link href="http://l.yimg.com/g/css/c_person.css.v75523.14" rel="stylesheet" type="text/css" />
27
+ <link href="http://l.yimg.com/g/css/c_bo_selecta.css.v999.1249110568?css/bo_selecta.css.14" rel="stylesheet" type="text/css" />
28
+
29
+
30
+ <!--[if LT IE 7]>
31
+ <style type="text/css">
32
+ .trans_png {
33
+ behavior: url('/javascript/pngbehavior2.htc');
34
+ border:0;
35
+ }
36
+ </style>
37
+ <![endif]-->
38
+
39
+
40
+ <script type="text/javascript">
41
+ var global_magisterLudi = '176220c1b43f687bec0233890b08c024',
42
+ global_auth_hash = 'b55e7f1d9055cd42f1aefe305f476424',
43
+ global_auth_token = '',
44
+ global_flickr_secret = '7dd6042c7270025e',
45
+ global_slideShowVersion = '6708',
46
+ global_slideShowCodeVersion = '34351',
47
+ global_slideShowVersionV2 = '33427',
48
+ global_slideShowCodeVersionV2 = '49745',
49
+ global_slideShowTextVersion = '66488',
50
+ global_slideShowVersionV3 = '71649',
51
+ global_nsid = '',
52
+ global_ispro = 0,
53
+ global_dbid = '',
54
+ global_name ='',
55
+ global_expire ='',
56
+ global_icon_url ='http://l.yimg.com/g/images/buddyicon.jpg#',
57
+ global_tag_limit = '75',
58
+ global_collection_depth_limit = 5,
59
+ global_stewartVersion = '71377',
60
+ global_contact_limit = '3000',
61
+ global_eighteen = 1,
62
+ global_group_limit = 10,
63
+ global_photos_ids_limit = 20,
64
+ disable_stewart = 0;
65
+ disable_geo = 0;
66
+ var global_rper = 0;
67
+
68
+ var global_widget_carets = 0;
69
+ var global_explore_search = 0;
70
+
71
+ var global_intl_lang = 'en-us';
72
+
73
+ var _photo_root = 'http://farm.static.flickr.com/';
74
+ var _site_root = 'http://www.flickr.com';
75
+ var _images_root = 'http://l.yimg.com/g/images';
76
+ var _intl_images_root = 'http://l.yimg.com/g/images/en-us';
77
+
78
+
79
+ var do_bbml = 1;
80
+
81
+ </script>
82
+
83
+
84
+ <script type="text/javascript" src="http://l.yimg.com/g/javascript/global.js.v75322.14"></script>
85
+
86
+ <script type="text/javascript">
87
+
88
+ </script>
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+
97
+
98
+
99
+
100
+
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+
111
+
112
+
113
+
114
+
115
+
116
+
117
+
118
+
119
+ <script type="text/javascript" src="http://l.yimg.com/g/javascript/fold_main.js.v48851.48851.48851.48851.48851.38771.48851.48851.75181.38771.71746.71745.62864.38771.66362.74013.74643.69832.38771.63688.38771.73289.67088.55944.73491.14"></script>
120
+
121
+
122
+ <script type="text/javascript" src="http://l.yimg.com/g/javascript/s_output_en-us.js.51889c51b467da68947223473edfe93f"></script>
123
+
124
+ <script type="text/javascript">
125
+
126
+ YAHOO.util.Event.addListener(window, 'load', F._window_onload);
127
+ YAHOO.util.Event.addListener(window, 'resize', F._window_onresize);
128
+ YAHOO.util.Event.addListener(window, 'blur', F._window_onblur);
129
+ YAHOO.util.Event.addListener(window, 'focus', F._window_onfocus);
130
+ YAHOO.util.Event.addListener(window, 'unload', F._window_onunload);
131
+
132
+ </script>
133
+
134
+
135
+
136
+ <script type="text/javascript">
137
+ var global_joinDate = F.convert_unix_time_stamp('');
138
+ var global_time_stamp = '090801000928';
139
+
140
+
141
+ fixMaxWidth_getWidth = (navigator.userAgent.match(/MSIE 6/i)?function(el) {
142
+ return el.currentStyle['max-width'];
143
+ }:function(el){
144
+ return el.currentStyle['maxWidth'];
145
+ });
146
+
147
+ fixMaxWidth = function(el) {
148
+ try {
149
+ el.runtimeStyle.behavior = 'none';
150
+ var mw = fixMaxWidth_getWidth(el);
151
+ var nmw = parseInt(mw,10) || 10000;
152
+ var cW = parseInt(el.offsetWidth);
153
+ var cH = parseInt(el.offsetHeight);
154
+ var ratio = (cH/cW);
155
+ if (el.offsetWidth>nmw) {
156
+ el.style.width = (nmw+'px');
157
+ if (!isNaN(cH) && cH) {
158
+ el.style.height = (Math.ceil(nmw*ratio)+'px');
159
+ }
160
+ }
161
+ } catch(e) {
162
+ // oh well
163
+ }
164
+ }
165
+
166
+
167
+
168
+ // Dean Edwards/Matthias Miller/John Resig
169
+
170
+ /* for Mozilla/Opera9 */
171
+ if (document.addEventListener) {
172
+ document.addEventListener("DOMContentLoaded", F._window_onload_dom, false);
173
+ }
174
+
175
+ /* for Internet Explorer */
176
+ /*@cc_on @*/
177
+ /*@if (@_win32)
178
+ document.write("<script id=__ie_onload defer src=javascript:void(0)><\/script>");
179
+ var script = document.getElementById("__ie_onload");
180
+ script.onreadystatechange = function() {
181
+ if (this.readyState == "complete") {
182
+ F._window_onload_dom(); // call the onload handler
183
+ }
184
+ };
185
+ /*@end @*/
186
+
187
+ /* for Safari */
188
+ if (/WebKit/i.test(navigator.userAgent)) { // sniff
189
+ F.onload_dom_timer = setInterval(function() {
190
+ if (/loaded|complete/.test(document.readyState)) {
191
+ F._window_onload_dom(); // call the onload handler
192
+ }
193
+ }, 10);
194
+ }
195
+
196
+
197
+
198
+ F.keyboardShortcuts.enableAll();
199
+
200
+ </script>
201
+
202
+ <!--[if IE]>
203
+ <style type="text/css">
204
+
205
+ img.notsowide {
206
+ behavior:expression(fixMaxWidth(this));
207
+ }
208
+
209
+ </style>
210
+ <![endif]-->
211
+
212
+ <script type="text/javascript" src="http://l.yimg.com/a/lib/map/js/api/ymapapi_3_8_2_1.js"></script>
213
+ <script type="text/javascript" src="http://l.yimg.com/g/javascript/photo_mini_map.js.v60180.14"></script>
214
+
215
+
216
+
217
+
218
+
219
+ <link rel="openid2.provider" href="https://open.login.yahooapis.com/openid/op/auth" /></head>
220
+
221
+ <body>
222
+
223
+ <div id="beacon"><img src="http://geo.yahoo.com/f?s=792600013&t=457b936d5eb3dfdac4926d4522ee0555&fl_ev=0&lang=en&intl=sg" width="0" height="0" alt="" /></div>
224
+
225
+ <a name="top"></a>
226
+
227
+
228
+
229
+
230
+
231
+
232
+
233
+
234
+ <div class="TopBar" id="TopBar">
235
+ <table cellspacing="0" class="Header" border="0">
236
+ <tr>
237
+ <td class="FlickrLogo">
238
+ <a href="/"><img src="http://l.yimg.com/g/images/flickr_logo_gamma.gif.v59899.14" id="FlickrLogo" width="98" height="26" alt="Flickr logo. If you click it, you'll go home" /> </a>
239
+ </td>
240
+ <td class="Status">
241
+
242
+
243
+ You aren't signed in
244
+ &nbsp;&nbsp;&nbsp;
245
+ <a href="/signin/">Sign In</a>
246
+ &nbsp;&nbsp;
247
+ <a href="/help/">Help</a>
248
+ </td>
249
+ </tr>
250
+ </table>
251
+ <table cellspacing="0" class="NavBar" border="0">
252
+ <tr>
253
+ <td class="Primary">
254
+
255
+ <div id="candy_nav_button_bar" class="candy_button_bar">
256
+ <ul class="site_nav_menu_buttons">
257
+
258
+ <li class="no_menu_li"><span><a href="/">Home</a></span></li>
259
+
260
+
261
+ <li class="no_menu_li"><span><a href="/tour/" alt="Take the Flickr tour">The Tour</a></span></li>
262
+
263
+ <li class="no_menu_li"><span><a href="/signup/" alt="Sign Up for a Free Account">Sign Up</a></span></li>
264
+
265
+
266
+
267
+ <li class="menu_li" id="candy_nav_button_explore"><span><a href="/explore/" alt="Explore Flickr">Explore</a> <img src="http://l.yimg.com/g/images/site_nav_caret_split_default.png" class="nav_button_caret" width="18" height="15" alt="More options"></span>
268
+ <div class="candy_menu" id="candy_nav_menu_explore">
269
+ <a href="/explore/">Explore Page</a>
270
+ <a href="/explore/interesting/7days/">Last 7 Days Interesting</a>
271
+ <a href="/photos/tags/">Popular Tags</a>
272
+ <a href="/explore/interesting/2009/08/">Calendar</a>
273
+ <a href="/photos/">Most Recent Uploads</a>
274
+ <a href="/explore/video/">Video on Flickr</a>
275
+ <a href="/analog/">Explore Analog</a>
276
+
277
+ <a href="/explore/clock/" title="Flickr Clock">Flickr Clock</a>
278
+
279
+ <!--<a href="/explore/interesting/2008/08/">A Year Ago Today</a>-->
280
+
281
+ <a title="Photos and videos on a map" href="/map/" class="menu_item_line_above">World Map</a> <a href="/places/">Places</a>
282
+ <a href="/commons/" class="menu_item_line_above">The Commons</a>
283
+ <a href="/creativecommons/">Creative Commons</a>
284
+
285
+ <a href="http://blog.flickr.com/" class="menu_item_line_above">FlickrBlog</a>
286
+ <a href="http://code.flickr.com/">code.flickr</a>
287
+ <a href="/services/">Flickr Services</a>
288
+
289
+ <a href="/do/more/" class="menu_item_line_above">Do More, Order Prints</a>
290
+ <a href="/cameras/">Camera Finder</a> </div>
291
+ </li>
292
+
293
+ </ul>
294
+ </div>
295
+ <script type="text/javascript">F.decorate(_ge('candy_nav_button_bar'), F._nav_button_bar).bar_go_go_go();</script>
296
+
297
+
298
+
299
+ </td>
300
+
301
+
302
+
303
+
304
+
305
+
306
+
307
+
308
+ <td id="search_header_form_td">
309
+ <form action="/search/" method="get" onsubmit="_do_header_search('80186783@N00', '', '/search/', '', '');return false;" id="headersearchform">
310
+ <input name="q" id="header_search_q" type="text" class="Box" value="Search David Lazar's photostream">
311
+ <input name="w" type="hidden" value="80186783@N00">
312
+ <input name="m" type="hidden" value="">
313
+ <input name="s" type="hidden" value="">
314
+ <input name="mt" type="hidden" value="">
315
+ <input name="referer_searched" type="hidden" value="">
316
+
317
+ <span id="headersearchbutton1"><input value="Search" type="image" src="http://l.yimg.com/g/images/header_search_button.png" /></span>
318
+ </form>
319
+ </td>
320
+ <td id="search_header_button_td" width="82">
321
+
322
+ <div id="candy_search_button_bar" class="candy_button_bar">
323
+ <ul class="site_nav_menu_buttons">
324
+ <li class="menu_li" id="candy_nav_button_search"><span><a href="/search/" onclick="_do_header_search('80186783@N00', '', '/search/', '', '');return false;">Search</a> <img src="http://l.yimg.com/g/images/site_nav_caret_split_default.png" class="nav_button_caret" width="18" height="15" alt="More options"></span>
325
+ <div class="candy_menu" id="candy_nav_menu_search">
326
+ <a title="Everyone's Uploads" href="/search/" onclick="_do_header_search('all', null, null, '', ''); return false;">Everyone's Uploads</a>
327
+ <a title="Groups" href="/search/groups/" onclick="_do_header_search('', '', '/search/groups/'); return false;">Groups</a>
328
+ <a title="Flickr Members" href="/search/people/" onclick="_do_header_search('', 'names', '/search/people/'); return false;">Flickr Members</a>
329
+ <a title="For a Location" href="/map/" onclick="_do_header_search('location', '', '/map/'); return false;">For a Location</a> <a class="menu_item_line_above" title="David Lazar's Photos" href="/search/" onclick="_do_header_search('80186783@N00', ''); return false;"><b>&#183;</b> David Lazar's Photostream</a>
330
+
331
+ </div>
332
+ </li>
333
+ </ul>
334
+ </div>
335
+
336
+ <script type="text/javascript">F.decorate(_ge('candy_nav_button_search'), F._nav_button).button_go_go_go();</script>
337
+
338
+ <script type="text/javascript">
339
+ var b1 = _ge('headersearchbutton1');
340
+ b1.parentNode.removeChild(b1);
341
+
342
+ _ge('search_header_form_td').style.paddingBottom = '2px';
343
+
344
+ _ge('candy_search_button_bar').style.display = 'block';
345
+
346
+
347
+ var f = _ge('headersearchform');
348
+
349
+ if (f.q.value == 'Search David Lazar\'s photostream') f.q.style.color = '#999';
350
+
351
+ f.q.onfocus = function() {
352
+ if (this.value == 'Search David Lazar\'s photostream') this.value = '';
353
+ this.style.color = '#222';
354
+ if (window.ymap) ymap._disableKeys = true;
355
+ }
356
+
357
+ f.q.onblur = function() {
358
+ if (this.value != '') return;
359
+ this.style.color = '#999';
360
+ this.value = 'Search David Lazar\'s photostream';
361
+ if (window.ymap) ymap._disableKeys = false;
362
+ }
363
+
364
+ var _do_header_search = function(w, m, action, s, mt) {
365
+ var f = _ge('headersearchform');
366
+ if (f.q.value == 'Search David Lazar\'s photostream') f.q.value = '';
367
+ f.q.value = f.q.value.trim();
368
+
369
+
370
+ // do location search if the location search window is open, or if w == 'location'
371
+ if (w == 'location' || (_ge('loc_search_div') && _ge('loc_search_div').style.display != 'none')) {
372
+ if (!_ge('loc_search_div')) {
373
+ // create the location search crap!
374
+ var div = document.createElement('div');
375
+ div.id = 'loc_search_div';
376
+ document.body.appendChild(div);
377
+
378
+ var page_type = 'site';
379
+ F.decorate(div, F._loc_search_div).div_go_go_go(page_type);
380
+ }
381
+ try {_ge('loc_search_div').div_do_loc_search()} catch(err) {writeDebug(err)};return false;
382
+ return;
383
+ }
384
+
385
+
386
+
387
+
388
+ f.w.value = w;
389
+ f.m.value = (m) ? m : '';
390
+ f.s.value = (s) ? s : '';
391
+ f.mt.value = (mt) ? mt : '';
392
+ f.action = (action) ? action : '/search/';
393
+
394
+ if (f.m.value == 'tags' && f.q.value && f.q.value.indexOf(' ') == -1) {
395
+ var alias = '';
396
+ alias = (alias) ? alias : f.w.value;
397
+ var turl = '/photos/';
398
+ if (f.w.value == 'all') {
399
+ turl+= 'tags/'+encodeURIComponent(f.q.value);
400
+ } else {
401
+ turl+= alias+'/tags/'+encodeURIComponent(f.q.value);
402
+ }
403
+ document.location = turl;
404
+ return;
405
+ }
406
+
407
+ var qsA = ['q='+encodeURIComponent(f.q.value)];
408
+ if (f.w.value) qsA.push('w='+encodeURIComponent(f.w.value));
409
+ if (f.m.value) qsA.push('m='+encodeURIComponent(f.m.value));
410
+ if (f.s.value) qsA.push('s='+encodeURIComponent(f.s.value));
411
+ if (f.mt.value) qsA.push('mt='+encodeURIComponent(f.mt.value));
412
+ if (f.referer_searched.value) qsA.push('referer_searched='+encodeURIComponent(f.referer_searched.value));
413
+
414
+ var surl = f.action+'?'+qsA.join('&');
415
+ document.location = surl;
416
+ }
417
+
418
+
419
+ </script>
420
+
421
+ </td>
422
+ </tr>
423
+ </table>
424
+ </div>
425
+
426
+ <div id="Main" class="">
427
+
428
+
429
+
430
+
431
+
432
+
433
+
434
+ <div id="photostream-join-container">
435
+ <div id="photostream-join-msg">
436
+ <div id="photostream-join-content">
437
+ <h2>David Lazar uses Flickr &ndash; so can you!</h2>
438
+ <p>Flickr is a great way to stay in touch with people and explore the world. It's free and fun!</p>
439
+ </div>
440
+ <div id="photostream-join-action">
441
+ <a class="ActionButt" href="/signup/"><strong>Join Flickr</strong></a>
442
+ </div>
443
+ <a href="#" id="photostream-join-close" title="Hide">X</a>
444
+ </div>
445
+ <div id="photostream-join-arrow"></div>
446
+ </div>
447
+ <script>
448
+
449
+ (function() {
450
+
451
+ var close_link = _ge('photostream-join-close');
452
+ close_link.style.display = 'block';
453
+
454
+ Y.E.on(close_link, 'click', function(e) {
455
+
456
+ close_link.blur();
457
+ Y.E.stopEvent(e);
458
+
459
+ _ge('photostream-join-container').style.display = 'none';
460
+
461
+ var date = new Date();
462
+ date.setTime(date.getTime() + (365 * 24 * 60 * 60 * 1000));
463
+ document.cookie = 'flhjm=1; expires=' + date.toUTCString() + '; path=/; domain=.flickr.com';
464
+ });
465
+
466
+ })();
467
+
468
+ </script>
469
+
470
+
471
+
472
+
473
+ <table width="800" cellspacing="0" id="SubNav">
474
+ <tr>
475
+ <td class="Buddy">
476
+ <a href="/photos/80186783@N00/"><img src="http://farm1.static.flickr.com/53/buddyicons/80186783@N00.jpg?1144377199#80186783@N00" alt="David Lazar's buddy icon" width="48" height="48" /></a>
477
+ </td>
478
+ <td class="Section">
479
+ <h1>
480
+ David Lazar's photostream
481
+
482
+ </h1>
483
+
484
+ <p class="LinksNewP"><span class="LinksNew"><span><a href="/photos/80186783@N00/sets/">Sets</a></span><span><a href="/photos/80186783@N00/tags/">Tags</a></span><span><a href="/photos/80186783@N00/archives/">Archives</a></span><span><a href="/photos/80186783@N00/favorites/">Favorites</a></span><a href="/people/80186783@N00/" rel="me">Profile</a></span><wbr><span class="photo_navi_contact" id="photo_navi_contact_span_80186783@N00"></span></p>
485
+
486
+ </td>
487
+ <td class="Extras">
488
+
489
+
490
+
491
+
492
+
493
+
494
+
495
+
496
+
497
+
498
+
499
+
500
+
501
+
502
+
503
+
504
+
505
+
506
+
507
+
508
+
509
+
510
+ <div class="SlideShowShareButtons">
511
+ <div id="SSButtonHugger">
512
+
513
+
514
+ <span class="slideshow-box"><a href="/photos/80186783@N00/show/" id="SlideShowButton"><span class="slideshow-link-wrapper">Slideshow</span></a></span>
515
+ </div>
516
+
517
+
518
+
519
+ </div>
520
+
521
+ <div id="GPTooltip">
522
+ <span style="display: none;" id="tooltip_1249110568_0">Guest Passes let you share your photos that aren't public. Anyone can see your public photos anytime, whether they're a Flickr member or not. But! If you want to share photos marked as friends, family or private, use a Guest Pass. If you're sharing photos from a set, you can create a Guest Pass that includes any of your photos marked as friends, family, or private. If you're sharing your entire photostream, you can create a Guest Pass that includes photos marked as friends or family (but not your private photos). <a href="/help/sharing/#2184" target="_blank">Learn more about Guest Passes!</a></span><span class="Tip">[<a href="#" onclick="this.blur(); show_tooltip(this, 'tooltip_1249110568_0', 599); return false;">?</a>]</span>
523
+ </div>
524
+
525
+
526
+
527
+
528
+ <img src="http://l.yimg.com/g/images/spaceball.gif" alt="spacer!" width="200" height="1" />
529
+ </td>
530
+ </tr>
531
+ </table>
532
+
533
+ <script type="text/javascript">
534
+ var photostream_owner_nsid = "80186783@N00";
535
+ </script>
536
+
537
+
538
+ <div id="div_mini_map_frame" style="position: absolute; left:-9500px">
539
+ <div id="div_mini_map_frame2">
540
+ <div id="map_links1" style="position: absolute; top:7px; left:9px; font-family: Arial; font-size: 11px; color: #999"></div>
541
+ <div id="div_mini_map_frame3">
542
+ <div id="map" style="position: absolute; top:3px; left:3px; width:510px; height:250px;"></div>
543
+ </div>
544
+ <div id="map_links2" style="position: absolute; bottom:7px; left:9px; width:360px; font-family: Arial; font-size: 11px; color: #999">
545
+ </div>
546
+ <div id="pretty_lat_long" style="position: absolute; right:7px; bottom:7px; font-family: Arial; font-size: 11px; font-style: italic; color: #999">pretty lat/long</div>
547
+ </div>
548
+ <a id="close_button" style="height:16px; overflow:visible"></a>
549
+ </div>
550
+
551
+
552
+
553
+ <table width="100%" cellspacing="0" cellpadding="0" class="PhotoStream">
554
+ <tr valign="top">
555
+ <td width="100%" valign="top" align="center" class="PhotosColumn">
556
+
557
+
558
+ <script type="text/javascript" src="http://l.yimg.com/g/javascript/photo_cols.js.v38771.14"></script>
559
+
560
+ <table width="100%" cellspacing="0">
561
+ <tr valign="bottom">
562
+ <td>
563
+ <div class="StreamView" id="sv_title_124484929">
564
+ <h4>Debian Box</h4>
565
+ </td>
566
+ <td>
567
+ <div class="StreamView" id="sv_title_124484928">
568
+ <h4>Debian Box</h4>
569
+ </td>
570
+ <td>
571
+ <div class="StreamView" id="sv_title_108756172">
572
+ <h4>Ruby on Rails Coding</h4>
573
+ </td>
574
+ </tr>
575
+ <tr valign="top">
576
+ <td>
577
+ <div class="StreamView" id="sv_body_124484929">
578
+
579
+ <p class="Photo" style="position:relative">
580
+ <span class="photo_container pc_m"><a href="/photos/80186783@N00/124484929/" title="Debian Box by David Lazar"><img src="http://farm1.static.flickr.com/38/124484929_ed8c345cb9_m.jpg" width="240" height="180" alt="Debian Box by David Lazar" class="pc_img" /></a></span>
581
+ </p>
582
+
583
+
584
+
585
+ An empty desktop.
586
+ <p class="Privacy">
587
+
588
+ <img src="http://l.yimg.com/g/images/spaceout.gif" alt="Anyone can see this photo" title="Anyone can see this photo" width="15" height="15" class="f-sprite fs-icon_public" />
589
+ <img src="http://l.yimg.com/g/images/spaceout.gif" border="0" height="15" width="15" class="f-sprite fs-icon_all_rights" /> All rights reserved </p>
590
+ <p class="Do">
591
+ Uploaded on <a href="/photos/80186783@N00/archives/date-posted/2006/04/06/" class="Plain">Apr 6, 2006</a>
592
+ </p>
593
+ <p class="Activity">
594
+ <a href="/photos/80186783@N00/124484929/" class="Plain">0 comments</a>
595
+
596
+ </p> </div>
597
+ </td>
598
+ <td>
599
+ <div class="StreamView" id="sv_body_124484928">
600
+
601
+ <p class="Photo" style="position:relative">
602
+ <span class="photo_container pc_m"><a href="/photos/80186783@N00/124484928/" title="Debian Box by David Lazar"><img src="http://farm1.static.flickr.com/38/124484928_b527114538_m.jpg" width="240" height="180" alt="Debian Box by David Lazar" class="pc_img" /></a></span>
603
+ </p>
604
+
605
+
606
+
607
+ Look at what the cow has to say!
608
+ <p class="Privacy">
609
+
610
+ <img src="http://l.yimg.com/g/images/spaceout.gif" alt="Anyone can see this photo" title="Anyone can see this photo" width="15" height="15" class="f-sprite fs-icon_public" />
611
+ <img src="http://l.yimg.com/g/images/spaceout.gif" border="0" height="15" width="15" class="f-sprite fs-icon_all_rights" /> All rights reserved </p>
612
+ <p class="Do">
613
+ Uploaded on <a href="/photos/80186783@N00/archives/date-posted/2006/04/06/" class="Plain">Apr 6, 2006</a>
614
+ </p>
615
+ <p class="Activity">
616
+ <a href="/photos/80186783@N00/124484928/" class="Plain">0 comments</a>
617
+
618
+ </p> </div>
619
+ </td>
620
+ <td>
621
+ <div class="StreamView" id="sv_body_108756172">
622
+
623
+ <p class="Photo" style="position:relative">
624
+ <span class="photo_container pc_m"><a href="/photos/80186783@N00/108756172/" title="Ruby on Rails Coding by David Lazar"><img src="http://farm1.static.flickr.com/39/108756172_fd2099f044_m.jpg" width="240" height="180" alt="Ruby on Rails Coding by David Lazar" class="pc_img" /></a></span>
625
+ </p>
626
+
627
+
628
+
629
+ Some Ruby on Rails fun.
630
+ <p class="Privacy">
631
+
632
+ <img src="http://l.yimg.com/g/images/spaceout.gif" alt="Anyone can see this photo" title="Anyone can see this photo" width="15" height="15" class="f-sprite fs-icon_public" />
633
+ <img src="http://l.yimg.com/g/images/spaceout.gif" border="0" height="15" width="15" class="f-sprite fs-icon_all_rights" /> All rights reserved </p>
634
+ <p class="Do">
635
+ Uploaded on <a href="/photos/80186783@N00/archives/date-posted/2006/03/06/" class="Plain">Mar 6, 2006</a>
636
+ </p>
637
+ <p class="Activity">
638
+ <a href="/photos/80186783@N00/108756172/" class="Plain">0 comments</a>
639
+
640
+ </p> </div>
641
+ </td>
642
+ </tr>
643
+ <tr valign="bottom">
644
+ <td>
645
+ <div class="StreamView" id="sv_title_108756171">
646
+ <h4>Windows 2k3 Desktop</h4>
647
+ </td>
648
+ <td>
649
+ &nbsp;
650
+ </td>
651
+ <td>
652
+ &nbsp;
653
+ </td>
654
+ </tr>
655
+ <tr valign="top">
656
+ <td>
657
+ <div class="StreamView" id="sv_body_108756171">
658
+
659
+ <p class="Photo" style="position:relative">
660
+ <span class="photo_container pc_m"><a href="/photos/80186783@N00/108756171/" title="Windows 2k3 Desktop by David Lazar"><img src="http://farm1.static.flickr.com/50/108756171_f4efb1543b_m.jpg" width="240" height="180" alt="Windows 2k3 Desktop by David Lazar" class="pc_img" /></a></span>
661
+ </p>
662
+
663
+
664
+
665
+ Me coding in Ruby on Win2k3
666
+ <p class="Privacy">
667
+
668
+ <img src="http://l.yimg.com/g/images/spaceout.gif" alt="Anyone can see this photo" title="Anyone can see this photo" width="15" height="15" class="f-sprite fs-icon_public" />
669
+ <img src="http://l.yimg.com/g/images/spaceout.gif" border="0" height="15" width="15" class="f-sprite fs-icon_all_rights" /> All rights reserved </p>
670
+ <p class="Do">
671
+ Uploaded on <a href="/photos/80186783@N00/archives/date-posted/2006/03/06/" class="Plain">Mar 6, 2006</a>
672
+ </p>
673
+ <p class="Activity">
674
+ <a href="/photos/80186783@N00/108756171/" class="Plain">1 comment</a>
675
+
676
+ </p> </div>
677
+ </td>
678
+ <td>
679
+ &nbsp;
680
+ </td>
681
+ <td>
682
+ &nbsp;
683
+ </td>
684
+ </tr>
685
+ </table>
686
+
687
+
688
+
689
+ <br clear="all" />
690
+ </td>
691
+ </tr>
692
+ </table>
693
+
694
+
695
+
696
+
697
+ <div id="Feeds">
698
+ <div id="AtomRSS">
699
+ <a href="http://api.flickr.com/services/feeds/photos_public.gne?id=80186783@N00&lang=en-us&amp;format=rss_200" title="RSS 2.0 feed"><img src="http://l.yimg.com/g/images/feed-icon-16x16.png" width="16" height="16" alt="Subscribe to a feed of stuff on this page..." class="absmiddle" /></a>
700
+ Subscribe to David Lazar's photostream &ndash; <span style="color:#ccc"><a href="http://api.flickr.com/services/feeds/photos_public.gne?id=80186783@N00&lang=en-us&amp;format=rss_200" title="RSS 2.0 feed">Latest</a> | <a href="http://api.flickr.com/services/feeds/geo/?id=80186783@N00&amp;lang=en-us&amp;format=rss_200" title="geoRSS feed">geoFeed</a> | <a href="http://api.flickr.com/services/feeds/geo/?id=80186783@N00&amp;lang=en-us&amp;format=kml_nl" title="Google Earth network link">KML</a></span>
701
+ </div>
702
+ <div id="AddToYahoo"><a href="http://us.rd.yahoo.com/my/atm/Flickr/Users/*http://add.my.yahoo.com/rss?url=http%3A%2F%2Fapi.flickr.com%2Fservices%2Ffeeds%2Fphotos_public.gne%3Fid%3D80186783%40N00%26lang%3Den-us%26format%3Drss_200"><img src="http://l.yimg.com/g/images/en-us/my_yahoo.gif" alt="Add to My Yahoo!" /></a></div>
703
+ </div>
704
+
705
+
706
+ <script>
707
+ deja_view_refresh();
708
+ </script>
709
+
710
+ </div><!--end Main-->
711
+
712
+ <br id="MainFooterClear" clear="all" />
713
+
714
+ <div id="FooterWrapper">
715
+ <div class="Footer">
716
+
717
+ <table class="Jump" cellspacing="0">
718
+
719
+ <tr>
720
+ <th class="To">
721
+ You
722
+ </th>
723
+ <td>
724
+ <a href="/signin/">Sign in</a> |
725
+ <a href="/signup/">Create Your Free Account</a>
726
+ </td>
727
+ </tr>
728
+ <tr>
729
+ <th class="To">
730
+ <a href="/explore/" class="Plain">Explore</a>
731
+ </th>
732
+ <td>
733
+ <a href="/places/">Places</a> |
734
+ <a href="/explore/interesting/7days/">Last 7 Days</a> |
735
+ <a href="/explore/interesting/2009/08/">This Month</a> |
736
+ <a href="/photos/tags/">Popular Tags</a> |
737
+ <a href="/commons/">The Commons</a> |
738
+ <a href="/creativecommons/">Creative Commons</a> |
739
+ <a href="/search/">Search</a>
740
+ </td>
741
+ </tr>
742
+ <tr>
743
+ <th class="To">
744
+ <a href="/help/" class="Plain">Help</a>
745
+ </th>
746
+ <td>
747
+ <a href="/guidelines.gne">Community Guidelines</a> |
748
+ <a href="/help/forum/">The Help Forum</a> |
749
+
750
+ <a href="/help/faq/">FAQ</a> |
751
+ <a href="/sitemap.gne">Sitemap</a> |
752
+ <a href="/help/">Get Help</a>
753
+ </td>
754
+ </tr>
755
+ </table>
756
+ <div class="Delicious">
757
+ </div>
758
+
759
+ <p class="About">
760
+
761
+ <span class="yahoo_logo">
762
+ <a href="http://www.yahoo.com/"><img src="http://l.yimg.com/g/images/spaceout.gif" width="99" height="11" alt="Flickr, a Yahoo! Company" class="f-sprite fs-logo_yahoo_company" /></a>
763
+ </span>
764
+
765
+ <a href="http://blog.flickr.net/">Flickr Blog</a> |
766
+ <a href="/about/">About Flickr</a> |
767
+ <a href="/terms.gne" onClick="window.open('/terms.gne','TOC','status=yes,scrollbars=yes,resizable=yes,width=600,height=480'); return false">Terms of Use</a> |
768
+ <a href="/privacy_policy.gne">Your Privacy</a> |
769
+ <a href="http://info.yahoo.com/legal/sg/yahoo/iprp/" target="_blank">Copyright/IP Policy</a> | <a id="ft-report-abuse" href="/report_abuse.gne">Report Abuse</a>
770
+
771
+ <p class="LanguageSelector" id="LanguageSelector">
772
+
773
+
774
+ <span>
775
+ <a href="/change_language.gne?lang=zh-hk&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" class="image_link" id="lang_zh-hk"><img src="http://l.yimg.com/g/images/lang_zh-tw_11px_default.png" width="45" height="13" id="langselect_zh-hk" alt="繁體中文"></a> <b>|</b>
776
+ <a href="/change_language.gne?lang=de-de&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" >Deutsch</a>
777
+ <b>|</b>
778
+ <a href="/change_language.gne?lang=en-us&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" class="selected">English</a>
779
+ <b>|</b>
780
+ <a href="/change_language.gne?lang=es-us&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" >Espa&#241;ol</a>
781
+ <b>|</b>
782
+ <a href="/change_language.gne?lang=fr-fr&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" >Fran&#231;ais</a>
783
+ <b>|</b>
784
+ <a href="/change_language.gne?lang=ko-kr&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" class="image_link" id="lang_ko-kr"><img src="http://l.yimg.com/g/images/lang_ko-kr_11px_default.png" width="23" height="13" id="langselect_ko-kr" alt="한글"></a> <b>|</b>
785
+ <a href="/change_language.gne?lang=it-it&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" >Italiano</a>
786
+ <b>|</b>
787
+ <a href="/change_language.gne?lang=pt-br&magic_cookie=b55e7f1d9055cd42f1aefe305f476424" >Portugu&#234;s</a>
788
+ </span>
789
+
790
+ <script type="text/javascript">if (_ge('langselect_zh-hk')) F.decorate(_ge('langselect_zh-hk'), F._link_button).button_go_go_go();</script>
791
+ <script type="text/javascript">if (_ge('langselect_ko-kr')) F.decorate(_ge('langselect_ko-kr'), F._link_button).button_go_go_go();</script>
792
+ Copyright &copy; 2009 Yahoo! Southeast Asia Pte Ltd (Co. Reg. No. 199700735D). All rights reserved.
793
+ </p> </p>
794
+
795
+
796
+ <br />
797
+
798
+
799
+ </div>
800
+ </div>
801
+ <div style="background: #000; color: #0f0; text-align: left; font-family: &quot;Courier New&quot;, Courier, monospace;"></div>
802
+
803
+
804
+
805
+
806
+
807
+ <script type="text/javascript">
808
+
809
+ try{
810
+ if (window.personmenu_init) personmenu_init(0);
811
+ } catch(er) {}
812
+
813
+ </script>
814
+
815
+
816
+
817
+
818
+ <!-- page generated by www75 (in mud) at 00:09:28 08/01/09 in 55ms -->
819
+
820
+
821
+
822
+ <script src="http://us.adserver.yahoo.com/a?f=792600013&p=flickr&l=FOOT9&c=r"></script>
823
+
824
+
825
+
826
+
827
+
828
+
829
+
830
+
831
+
832
+
833
+ </body>
834
+ </html>