Rail2 and Rails3 beta3 process <%= '<h1>hello</h1>' %> differently

Rail2 and Rails3 beta3 process <%= ‘

hello

’ %> differently.

Rails3 must use <%= capture {‘

hello

’} %> to get the same
result as Rails2

Is this intentional or is it a bug?

Rails 3 escapes content by default now.

See RailsDispatch.com is for sale | HugeDomains for more details.

So, now you have to use either:

<%=raw ‘

hello

’ %>

Or:

<%= ‘

hello

’.html_safe %>

Regards
Kieran

On May 8, 2:37 pm, “[email protected][email protected]