Re: [Rails] Re: Using Rails for consuming a web service
On 15 March 2011 15:02, Sebastian <sebastian.goldt@googlemail.com> wrote:
> My controller is looking this:
>
> def index
> @var1 = Mywebservice.new(params[:value1], params[:value1],
> params[:value1]) if params[:value1]
> end
Don't you mean :
@var1 = Mywebservice.new(params[:value1], params[:value2],
params[:value3]) if params[:value1] && params[:value2] && params[:value3]
In your code, you're not access value2 or value3...
> I don't know if my code is beautiful, but it is working!!
It may not be beautiful, but working is the important thing - beauty
is a bonus! :-)
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home