On Tue, Aug 28, 2007 at 06:37:47PM -0400, Matt Aimonetti
wrote:> dumb question but what''s the view format in trunk?
> I have a simple router:
> Merb::Router.prepare do |r|
> # default route, usually you don''t want to change this
> r.default_routes
>
> # change this for your home page to be avaiable at /
> r.add ''/'', :controller =>
''upload'', :action =>''new''
> end
> I have a simple controller which should render the view:
> def new
> @photo = Photo.new
> respond_to do |format|
> format.html { render }
> end
> end
> and in my app/views folder I have an upload folder and inside it a
> new.html.erb file but it doesn''t get picked up.
> No template matched
> /Users/matta/rails_projects/my_app/trunk/upload_manager/app/views/uplo
> ad/new.{}
> I tried adding a .herb file and .html but it didn''t help.
You now need to explicitly load the ERB handler, since it''s set to
autoload.
Just add the following line to conf/merb_init.rb:
Merb::Template::Erubis
If you start a fresh project you should get a suitable merb_init.rb
Regards,
Brian.