Sunday, December 13, 2009

Re: [Rails] Need help...NameError in InteractController#add_to_cart

Though I have only been playing with Rails for about a month, I think I can
answer this one.

You need to define add_a_cart in the store_controller.rb.

Good luck.

*susan*

> Hi,I am developing a web app and am following the text-Agile web
> development.....
> Each time I click my "add to cart" button" i always get the page below:I have
> double checked to see if i have errors in my code,there was none,please what
> do i need to do to proceed?
>
> NameError in InteractController#add_to_cart
> undefined local variable or method `find_cart' for
> #<InteractController:0x1042d0780>
> RAILS_ROOT:
> /Users/oluwayomioluwadara/Documents/CED/coursework/heritage/heritageApplicatio
> n Trace <http://0.0.0.0:3000/interact/add_to_cart/17#> | Framework Trace
> <http://0.0.0.0:3000/interact/add_to_cart/17#> | Full Trace
> <http://0.0.0.0:3000/interact/add_to_cart/17#>
> /Users/oluwayomioluwadara/Documents/CED/coursework/heritage/heritage/app/contr
> ollers/interact_controller.rb:8:in `add_to_cart'
> /Library/Ruby/Gems/1.8/gems/actionpack-2.3.4/lib/action_controller/base.rb:133
> 1:in `send'
> /Library/Ruby/Gems/1.8/gems/actionpack-2.3.4/lib/action_controller/base.rb:133
> 1:in `perform_action_without_filters'
> /Library/Ruby/Gems/1.8/gems/actionpack-2.3.4/lib/action_controller/filters.rb:
> 617:in `call_filters'Regards and Respects,
>
>
> Kindness in thought leads to wisdom.
> Kindness in speech leads to eloquence.
> Kindness in action leads to love.
>
>
>
>
> --
> 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.
>


--

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


Real Estate