I am running into this issue, I am a super newbie when it comes to ruby on rails, mysql. I am a front-end developer trying to get into more of a MVC type structured language, and ruby on rails seemed like the one. Here is the issue I am having. I have created a post through rails c i go back to browser localhost:3000/posts and it displays My Blog! --this is the blog title Hello Blog! --this is the post title Hi guys! This is my first entry :) --this is the body content NOT SURE WHAT THIS IS BELOW AND HOW TO STOP IT FROM APPEARING. I was wondering if it was some kind of debugging system. I have no clue. Would love the help. [#<Post id: 1, title: "Hello Blog!", body: "Hi guys! This is my first entry :)", created_at: "2010-04-22 03:10:34", updated_at: "2010-04-22 03:10:34">] Thank you. -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Post your view code. On Apr 21, 10:20 pm, Michael Michael <li...-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> I am running into this issue, I am a super newbie when it comes to ruby > on rails, mysql. I am a front-end developer trying to get into more of a > MVC type structured language, and ruby on rails seemed like the one. > > Here is the issue I am having. > > I have created a post through rails c > > i go back to browser localhost:3000/posts and it displays > > My Blog! --this is the blog title > > Hello Blog! --this is the post title > > Hi guys! This is my first entry :) --this is the body content > > NOT SURE WHAT THIS IS BELOW AND HOW TO STOP IT FROM APPEARING. I was > wondering if it was some kind of debugging system. I have no clue. Would > love the help. > > [#<Post id: 1, title: "Hello Blog!", body: "Hi guys! This is my first > entry :)", created_at: "2010-04-22 03:10:34", updated_at: "2010-04-22 > 03:10:34">] > > Thank you. > -- > Posted viahttp://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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. > For more options, visit this group athttp://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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@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.
<h1>My Blog!</h1> <%= @posts.each do |post| %> <h2><%= post.title %></h2> <div class="entry"> <%= post.body %> <hr /> </div> <% end %> -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
I think i found the problem I had <%= @posts.each do |post| %> instead of <% @posts.each do |post| %> I just realized that, because having <%= outputs right? Thanks for responding, I appreciate it. -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
"Michael Michael" <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote in message news:fce2a0ce9e610603f85b4cff455f6153-fsXkhYbjdPvAG73buMG3tuG/Ez6ZCGd0@public.gmane.org>I think i found the problem I had > > <%= @posts.each do |post| %> > > instead of > > <% @posts.each do |post| %> > > I just realized that, because having <%= outputs right?Yep, that sure sounds like that would be the problem. :D -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.