From: Dan Cruickshank Date: 2010-05-14T04:56:47+09:00 Subject: Re: Need help using Savon gem! (SOAP) I wish I had such luck. That doesn't work me. There must something else a foot on my machine. Following some other old threads looking at issues with soap4r, I put this a the top of my environment.rb and it worked (!!!!!) : require "rubygems" gem "soap4r" require "soap/soap" require "soap/wsdlDriver" The - require "soap/soap" - line seems key. Thank you so much for all of your help! Brian Candler wrote: > Dan Cruickshank wrote: >> Does anything above help us solve this quicker? I've created a new bare >> bones rails application and it fails as well with called in a >> controller. > > I created a bare-bones rails-2.3.4 application, with one controller: > script/generate controller hello > > and it works fine with > [app/controllers/hello_controller.rb] > require 'soap/wsdlDriver' > class HelloController < ApplicationController > def world > soap = > ::SOAP::WSDLDriverFactory.new("https://ws.interfax.net/dfs.asmx?WSDL") > render :text => "Hello!" > end > end > > And so does the following: > [app/controllers/hello_controller.rb] > require 'soaptest' > class HelloController < ApplicationController > def world > Soaptest.get_soap > render :text => "Hello!" > end > end > > [lib/soaptest.rb] > module Soaptest > def self.get_soap > ::SOAP::WSDLDriverFactory.new("https://ws.interfax.net/dfs.asmx?WSDL") > end > end -- Posted via http://www.ruby-forum.com/.