INSTALLATION:
Ruby 1.8.2
Rails 1.0.0
rubyful_soup 1.0.4 (GEM)
FACTS:
0) I have successfully installed the rubyful_soup GEM using (I had
previously installed it, which is why the output may look sparse):
C:\ruby>gem install -r rubyful_soup
Attempting remote installation of ‘rubyful_soup’
Successfully installed rubyful_soup-1.0.4
Installing RDoc documentation for rubyful_soup-1.0.4…
- I have a controller. The first 4 lines are:
require ‘rubygems’
require_gem ‘rubyful_soup’, ‘>= 1.0.4’
class ESimplyController < ApplicationController
- In this controller I have a method. Here it is:
public
def index
parser = BeautifulSoup.new(String.new “test”) #Establish the parse
tree
end
When I execute this action, I get:
“uninitialized constant BeautifulSoup”
which basically tells me that the BeautifulSoup class within the
rubyful_soup.rb file can’t be seen.
- Inside of the rubyful_soup.rb file, the BeautifulSoup class is
defined, like so:
class BeautifulSoup < BeautifulStoneSoup
…
QUESTION 1: Have I correctly included this RubyGem?
QUESTION 2: Does something else need to be done to successfully export
the BeautifulSoup class name so that it’s accessible?
QUESTION 3: Does something else need to be done to successfully import
the BeautifulSoup class name so that it’s accessible?
Thanks for any help that you can provide. I am at my wit’s end.
To top it all off, at random times and under circumstances that I am
unable to recreate, this was totally working for me. I do not
understand what is wrong.
Thanks,
Wes