]> gitweb.michael.orlitzky.com - dead/whatever-dl.git/blobdiff - src/websites/infoq.rb
Factored out the Youtube implementation of get_page_data into the Website superclass.
[dead/whatever-dl.git] / src / websites / infoq.rb
index fe05562508e61ca7e73ec31d793376016c4ff267..1829c8c2c5fd846682adb63b9e3b9b9e6b132585 100644 (file)
@@ -28,8 +28,8 @@ class Infoq < Website
   end
 
   
-  def get_video_url(url)
-    page_data = self.get_page_data(url)
+  def get_video_url()
+    page_data = self.get_page_data(@url)
     video_url = self.parse_video_url(page_data)
     return video_url
   end
@@ -55,15 +55,4 @@ class Infoq < Website
   end
 
 
-  # Just make a normal HTTP "get" request.
-  def get_page_data(url)
-    uri = URI.parse(url)
-    
-    response = Net::HTTP.start(uri.host, uri.port) do |http|
-      http.get(uri.path)
-    end
-    
-    return response.body
-  end
-
 end