I''m trying to learn to debug my Rails code. What types of errors cause the "Template is Missing" error? Coming from a php environment, this appears cryptic - but I''m betting it should be obvious to me. Thanks in advance ---Michael -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
You probably have a method in your controller which has no corresponding .rhtml, .rjs or .rxml (maybe?) file in views/your_controller_name. You need at least one of those for each of your public controller methods... I think. If you''re writing methods where you won''t have any corresponding webpage, rjs scripts, etc then make a private method or a helper method. I think that''s all right. I''m sure someone more knowledgeable than me will point me out if I''ve led you astray. On 9/18/06, Michael Satterwhite <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> > > I''m trying to learn to debug my Rails code. What types of errors cause > the "Template is Missing" error? Coming from a php environment, this > appears cryptic - but I''m betting it should be obvious to me. > > Thanks in advance > ---Michael > > -- > Posted via http://www.ruby-forum.com/. > > > >-- Terry (TAD) Donaghe http://www.tadspot.com http://www.rubynoob.com --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Terry Donaghe wrote:> I think that''s all right. I''m sure someone more knowledgeable than me > will > point me out if I''ve led you astray.Thanks for your info. I''m hoping to get several responses. I''m trying to learn Rails, and some of the concepts are foreign to the "traditional" way of doing thing. Thanks again. ---Michael -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Hi Michael, Michael Satterwhite wrote:> I''m trying to learn Rails, and some of the concepts > are foreign to the "traditional" way of doing thing.Depends on how far back your "tradition" goes ;-) A lot of the concepts in Rails were used in client/server computing. But if a person''s experience base didn''t predate the web (i.e., going on 8-10 years now), I imagine concepts like MVC and solid OO language constructs could be new. Many Rails concepts aren''t so much new as they are new to the web development domain. Best regards, Bill --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Bill Walton wrote:> Hi Michael, > > Michael Satterwhite wrote: > >> I''m trying to learn Rails, and some of the concepts >> are foreign to the "traditional" way of doing thing. > > Depends on how far back your "tradition" goes ;-)I go back to 1970. I''ve been in the field a *LONG* time.> A lot of the concepts > in > Rails were used in client/server computing. But if a person''s > experience > base didn''t predate the web (i.e., going on 8-10 years now), I imagine > concepts like MVC and solid OO language constructs could be new. Many > Rails > concepts aren''t so much new as they are new to the web development > domain.I won''t argue that at all. While you *CAN* program objects in PHP, it is kinda an add-on (I''m sure I''ll get yelled at for that - but it is). Ruby starts out object oriented. It still begs the original question. What types of errors in the code cause a "Template is missing" error. It helps to have a starting point to debug. -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Michael, If you don''t already have it, I very strongly recommend that you buy the 2nd Edition of Agile Web Development with Rails from the pragmattic programmers. It''s currently only available as a PDF purchase, but it''s well worth every penny and will teach you the "traditional" ways to do rails, more or less. Check here: http://www.pragmaticprogrammer.com/titles/rails2/index.html On 9/19/06, Bill Walton <bill.walton-xwVYE8SWAR3R7s880joybQ@public.gmane.org> wrote:> > > Hi Michael, > > Michael Satterwhite wrote: > > > I''m trying to learn Rails, and some of the concepts > > are foreign to the "traditional" way of doing thing. > > Depends on how far back your "tradition" goes ;-) A lot of the concepts > in > Rails were used in client/server computing. But if a person''s experience > base didn''t predate the web (i.e., going on 8-10 years now), I imagine > concepts like MVC and solid OO language constructs could be new. Many > Rails > concepts aren''t so much new as they are new to the web development domain. > > Best regards, > Bill > > > > >-- Terry (TAD) Donaghe http://www.tadspot.com http://www.rubynoob.com --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Michael Satterwhite wrote:> Bill Walton wrote: >> >> Depends on how far back your "tradition" goes ;-) > > I go back to 1970. I''ve been in the field a *LONG* time.Damn! That IS a *LONG* time ;-) I didn''t get started til ''80.> It still begs the original question. What types of errors in > the code cause a "Template is missing" error.The previous reply from Terry Donaghe was correct with respect to what causes the error: lack of a View. The default view that Rails looks for is one that has the same name as the controller action last executed in the request/response cycle. The view used can be explicitly over-ridden in the controller action with either render or redirect_to. The render can also be used to tell Rails not to render anything at all which is especially helpful when you''re using Ajax to update the database incrementally. The largest cause of the error for me has been fat-fingered typos. I''ll also second Terry''s suggestion re: reading material. hth, Bill --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Terry Donaghe wrote:> Michael, > > If you don''t already have it, I very strongly recommend that you buy the > 2nd > Edition of Agile Web Development with Rails from > the pragmattic programmers. It''s currently only available as a PDF > purchase, but it''s well worth every penny and will teach you the > "traditional" ways to do rails, more or less.I have it and can''t praise it high enough. It''s a mojor reference for me - not the only reference, of course, but an important one. ---Michael -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---