search for: new_post_path

Displaying 5 results from an estimated 5 matches for "new_post_path".

2012 Nov 01
2
SyntaxError in Posts#index
getting this error compile error /Users/bradwrage/webapps/blog/app/views/posts/index.html.erb:5: syntax error, unexpected ''='' ...w Goal", new_post_path, class="btn btn-success" );@output_bu... ^ /Users/bradwrage/webapps/blog/app/views/posts/index.html.erb:7: syntax error, unexpected kDO_BLOCK, expecting kEND ''); @posts.each do |post| ^ /Users/bradwrage/webapps/blog/app/views/pos...
2011 Jan 06
2
Link_to parameters
Hello, I would like to have a link_to automatically populate a field in the form that it is linking to. For example (excuse my silly words, im trying to make a point) <%= link_to "Add a COOL Post", new_post_path, :howcoolisit => ''COOL'' %> <%= link_to "Add a NOTCOOL Post", new_post_path, :howcoolisit => ''NOTCOOL'' %> Then, I would have a field in that form: <%= f.hidden_field :howcoolisit %> And I would want it to be populated automati...
2011 Apr 30
8
"uninitialized constant PostsController::Post"
...ationController def index @post=Post.new end def create @post = Post.new(params[:post]) respond_to do |format| end end end 2)index.html.erb <h1>Posts#index</h1> <p>Find me in app/views/posts/index.html.erb</p> <%= link_to ''New Post'', new_post_path%> <%= form_for(@post) do |f| %> <div class="field"> <%= f.label :name %><br /> <%= f.text_field :name %> </div> <div class="field"> <%= f.label :title %><br /> <%= f.text_field :title %> </d...
2012 Feb 17
1
link_to param body
...#39;'m developing an application, in this application I have a link that redirects me to other page. The problem is: -I want to add some params to this url, but I wanna hide this params "Like post request"(on the request body). How should I do it? <%= link_to "New Post", new_post_path %> -- Bruno Meira -- 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 rubyonra...
2011 May 19
0
Unable to find the image path via file system using the paperclip plugin through the get method
...td><%= link_to ''Destroy'', post, :confirm => ''Are you sure?'', :method => :delete %></td></tr> </table> <br/> <hr/> <% end %> <br /> <%= link_to ''New post'', new_post_path %> This is what I get doing a **tail -f log/development.log** ActionController::RoutingError (No route matches "/photo/4/original/ruby-on-rails.jpg" with {:method=>:get}): /home/mohnish/.rvm/gems/ruby-1.8.7-p334/gems/actionpack-2.0.2/lib/action_controller/routing.rb:...