So a few months ago I put together a side project at http://www.myrecipesavour.com/ . Basically, the site allows you to put in the URL of a cooking recipe page and will then parse the recipe for your collection. So it turns out, reading data from another site is very easy with Nokogiri. The source code is available here https://github.com/abreckner/MyRecipeSavour There is a lot I am going to cover in the next few posts based on this code base (like Devise and Heroku), but for now we are focussed on this file https://github.com/abreckner/MyRecipeSavour/blob/master/app/models/site.rb So we are going to look at the add_recipe method. First we need to require a few packages require 'open-uri' require 'rubygems' require 'nokogiri' Unfortunately, I haven't yet figured out a heuristic for separating a recipe web page into a recipe's components (Title, Ingredients, Instructions, Amounts, etc...) but as a workaround, I maintain a catalo
This is my technical blog where I note things I have developed that I want to remember.