hi this is my htnl
<html>
<head>
<%= javascript_include_tag :defaults %>
</head>
<body>
<%= form_tag nil, { :id => ''search_form'' } %>
<%= text_field ''recipe'', ''name'' %>
<%= end_form_tag %>
<div id="recipe">
</div>
<%= observe_form :search_form, :frequency => 0.5,
:update => ''recipe'',
:url => { :action => ''search_ajax'' } %>
</body>
</html>
below is the error i am getting
Action Controller: Exception caught
Showing *room/search.html.erb* where line *#9* raised:
You have a nil object when you didn''t expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]
any idea
--
Karthik.k
Mobile - +91-9894991640
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---
<% form_tag nil, :id => ''search_form'' do %> <%= text_field ''recipe'', ''name'' %> <% end %> works fine On 29 июл, 10:51, karthik k <cse.k.kart...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> hi this is my htnl > > <html> > <head> > <%= javascript_include_tag :defaults %> > </head> > <body> > <%= form_tag nil, { :id => ''search_form'' } %> > <%= text_field ''recipe'', ''name'' %> > <%= end_form_tag %> > > <div id="recipe"> > </div> > > <%= observe_form :search_form, :frequency => 0.5, > :update => ''recipe'', > :url => { :action => ''search_ajax'' } %> > </body> > </html> > > below is the error i am getting > Action Controller: Exception caught > > Showing *room/search.html.erb* where line *#9* raised: > > You have a nil object when you didn''t expect it! > You might have expected an instance of ActiveRecord::Base. > The error occurred while evaluating nil.[] > > any idea > -- > Karthik.k > Mobile -+91-9894991640
hi Rakoth Thank you Is there any good tutorial where i can search for text using ajax ruby on rails I am using rails 2.3.2 -- Karthik.k Mobile - +91-9894991640 On Wed, Jul 29, 2009 at 1:32 PM, Rakoth <rakoth3d-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > <% form_tag nil, :id => ''search_form'' do %> > <%= text_field ''recipe'', ''name'' %> > <% end %> > > works fine > > On 29 июл, 10:51, karthik k <cse.k.kart...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > hi this is my htnl > > > > <html> > > <head> > > <%= javascript_include_tag :defaults %> > > </head> > > <body> > > <%= form_tag nil, { :id => ''search_form'' } %> > > <%= text_field ''recipe'', ''name'' %> > > <%= end_form_tag %> > > > > <div id="recipe"> > > </div> > > > > <%= observe_form :search_form, :frequency => 0.5, > > :update => ''recipe'', > > :url => { :action => ''search_ajax'' } %> > > </body> > > </html> > > > > below is the error i am getting > > Action Controller: Exception caught > > > > Showing *room/search.html.erb* where line *#9* raised: > > > > You have a nil object when you didn''t expect it! > > You might have expected an instance of ActiveRecord::Base. > > The error occurred while evaluating nil.[] > > > > any idea > > -- > > Karthik.k > > Mobile -+91-9894991640 > > >--~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org 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 -~----------~----~----~----~------~----~------~--~---
hi Rakoth
<%= form_tag :acton=>''dummy''%>
<%= text_field_tag :search_name%>
<%= form_tag%>
<div id="room">
</div>
<%= observe_field(:search_name,:frequency =>
0.25,:ulr=>{:action=>''search_ajax''},:with=>"prefix",:update=>:room)%>
above is my page
i get error
in observe_field as
Action Controller: Exception caughtNoMethodError in Room#search
Showing *room/search.html.erb* where line *#14* raised:
You have a nil object when you didn''t expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]
Extracted source (around line *#14*):
11: <%= form_tag%>
12: <div id="room">
13: </div>
14: <%= observe_field(:search_name,:frequency =>
0.25,:ulr=>{:action=>''search_ajax''},:with=>"prefix",:update=>:room)%>
15: </body>
16: </html>
please help
I am very new to ruby on rails
--
Karthik.k
Mobile - +91-9894991640
On Wed, Jul 29, 2009 at 2:06 PM, karthik k
<cse.k.karthik-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> hi Rakoth
>
> Thank you
>
> Is there any good tutorial where i can search for text using ajax ruby on
> rails
> I am using rails 2.3.2
>
> --
> Karthik.k
> Mobile - +91-9894991640
>
>
> On Wed, Jul 29, 2009 at 1:32 PM, Rakoth
<rakoth3d-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>
>>
>> <% form_tag nil, :id => ''search_form'' do %>
>> <%= text_field ''recipe'', ''name''
%>
>> <% end %>
>>
>> works fine
>>
>> On 29 июл, 10:51, karthik k
<cse.k.kart...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>> > hi this is my htnl
>> >
>> > <html>
>> > <head>
>> > <%= javascript_include_tag :defaults %>
>> > </head>
>> > <body>
>> > <%= form_tag nil, { :id => ''search_form'' }
%>
>> > <%= text_field ''recipe'',
''name'' %>
>> > <%= end_form_tag %>
>> >
>> > <div id="recipe">
>> > </div>
>> >
>> > <%= observe_form :search_form, :frequency => 0.5,
>> > :update => ''recipe'',
>> > :url => { :action => ''search_ajax'' }
%>
>> > </body>
>> > </html>
>> >
>> > below is the error i am getting
>> > Action Controller: Exception caught
>> >
>> > Showing *room/search.html.erb* where line *#9* raised:
>> >
>> > You have a nil object when you didn''t expect it!
>> > You might have expected an instance of ActiveRecord::Base.
>> > The error occurred while evaluating nil.[]
>> >
>> > any idea
>> > --
>> > Karthik.k
>> > Mobile -+91-9894991640
>> >>
>>
>
>
>
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
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
-~----------~----~----~----~------~----~------~--~---
Hi! You can find documentation for PrototypeHelper with good examples here: http://api.rubyonrails.org/classes/ActionView/Helpers/PrototypeHelper.html On 29 июл, 12:36, karthik k <cse.k.kart...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> hi Rakoth > > Thank you > > Is there any good tutorial where i can search for text using ajax ruby on > rails > I am using rails 2.3.2 >
Also, always check your code, maybe even get your hands on a good development environment:> <%= observe_field(:search_name,:frequency => > 0.25,:ulr=>{:action=>''search_ajax''},:with=>"prefix",:update=>:room)%>What''s an "ulr"? :)
hi jhaagmans thank you i found myself I am very new to this ruby on rails, but i need support from you experts Thank you -- Karthik.k Mobile - +91-9894991640 On Wed, Jul 29, 2009 at 2:38 PM, jhaagmans <jaap.haagmans-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > Also, always check your code, maybe even get your hands on a good > development environment: > > > <%= observe_field(:search_name,:frequency => > > 0.25,:ulr=>{:action=>''search_ajax''},:with=>"prefix",:update=>:room)%> > > What''s an "ulr"? :) > > >--~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---