Pastie now auto-senses if line-wrap is a bad or good idea. Feedback?
## mark a section (Learn more)
This paste will be private.
##Controller (application.rb) def flag render :partial =>'flag', :locals => { :controller_name => "2", @action_name => params[:action_name] } end ## The partial _flag.rhtml 2 should appear here: <%= controller_name %> ## error <h1> NameError in Sell#subject_selected </h1> <p> Showing <i>app/views/layouts/_flag.rhtml</i> where line <b>#2</b> raised: <pre><code>undefined local variable or method `controller_name' for #<#<Class:0x4d83570>:0x4d83540></code></pre> </p>
From the Design Piracy series on my blog: