我安装了Active Support 3.0.3,使用Ruby 1.8.7安装了Rails 3.0.3.
当我尝试使用时,1.week.ago我得到了
NoMethodError: undefined method 'week' for 1:Fixnum
from (irb):2
Run Code Online (Sandbox Code Playgroud)
其他核心扩展似乎有效.我在一个朋友的计算机上尝试过(同样的安装规范和旧版本),结果相同.
是什么赋予了?
所有这些都在IRB中.
我不熟悉active_support,所以请耐心等待!
Fox的库允许通过谷歌的API搜索,但它需要积极的支持.我似乎无法让它工作!有任何想法吗?
require 'rubygems'
require 'active_support'
require 'google_search'
p GoogleSearch.web :q => "Hello World!"
Run Code Online (Sandbox Code Playgroud)
给我:
NoMethodError: undefined method ‘cattr_accessor’ for GoogleSearch:Class
Run Code Online (Sandbox Code Playgroud)
我有什么想法我做错了吗?