Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>The latest Erubis (2.6.4) and Rails 2.2 (and 2.3) are still not compatible. The main issue is that the generated ruby code from Erubis uses "_buf" as the buffer variable and Rails 2.2 and 2.3 require "@output_buffer" to be used.</p> <p>The reason for "@output_buffer" to be used is that ActionView helpers like CaptureHelper are designed around "@output_buffer" being the primary buffer in the generated code.</p> <p>I have created a gem called <a href="http://github.com/elkinsware/erubis_rails_helper/tree/master" rel="nofollow noreferrer">elkinsware-erubis_rails_helper</a> that fixes these issues and allows Erubis and Rails 2.3 (for sure but it should work for 2.2). </p> <p>In your environment.rb file add:</p> <pre><code> config.gem 'erubis' , :version =&gt; '2.6.4' config.gem 'elkinsware-erubis_rails_helper', :lib =&gt; 'erubis_rails_helper', :source =&gt; 'http://gems.github.com' </code></pre> <p>And then you can add a config/initializers/erubis_config.rb where you can adjust the Erubis/Rails options.</p> <pre><code> #Erubis::Helpers::RailsHelper.engine_class = Erubis::Eruby # or Erubis::FastEruby #Erubis::Helpers::RailsHelper.init_properties = {} #Erubis::Helpers::RailsHelper.show_src = false #Erubis::Helpers::RailsHelper.preprocessing = true </code></pre> <p>The source is at <a href="http://github.com/elkinsware/erubis_rails_helper/tree/master" rel="nofollow noreferrer">http://github.com/elkinsware/erubis_rails_helper/tree/master</a></p> <p>Let me know if you have any issues with the gem.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload