You can try making any *.rb file in config/initializers (these file
are autoloaded when starting server).
Yo can make any *.rb file in lib directory and require it within
environment.rb
You can also make a plugin in which you will have only init.rb with
"require 'xxx'" inside and lib directory with xxx.rb (and code
inside).

In my solution I have a separate plugin in which I've extracted DRYML
part of hobo and have those overrides loaded AFTER hobo dryml libs.

On Dec 21, 8:35 am, roland oth <[email protected]> wrote:
> Hello stevo
>
> Can you give a hint what a good file would be to past this in?
>
> thanx
>
> Am 20.12.2008 um 13:19 schrieb stevo84:
>
>
>
> >http://pastie.org/343841
>
> > Place this piece of code somewhere where it would override default
> > classes and it will enable you to use at least form_for and form_tag.
> > I do not claim that this is perfect solution but it works. Still I am
> > waiting for something "more official".
>
> > On Dec 19, 10:48 pm, Micah <[email protected]> wrote:
> >> I ran into the same problem. It looks like the Hobo DRYML tag takes
> >> over the standard Rails form helpers. I ended up just using the DRYML
> >> form tag, as it comes with a bunch of implicit context automagic fun.
> >> It would be nice to be able to use the standard Rails form helpers
> >> though. Especially when converting an existing app to Hobo.
>
> >> On Dec 17, 6:04 am, stevo84 <[email protected]> wrote:
>
> >>> As in subject. When trying to use on of those helpers I receive:
>
> >>> You have a nil object when you didn't expect it!
> >>> You might have expected an instance of Array.
> >>> The error occurred while evaluating nil.<<
>
> >>> Extracted source (around line #5):
>
> >>> 2:
> >>> 3: <column-mc:>
> >>> 4:
> >>> 5: <% form_for :user, :url => "/test/test" do |f| %>
> >>> 6: <%= f.error_messages %>
> >>> 7: <p>Please enter new password and confirmation.</p>
> >>> 8: <fieldset style="width: 400px; margin-bottom: 25px;">
>
> >>> Trace:
>
> >>> c:/ruby/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_view/
> >>> helpers/text_helper.rb:42:in `concat'
> >>> c:/ruby/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_view/
> >>> helpers/form_helper.rb:252:in `form_for'
> >>> app/views/test/index.dryml:5:in `render_page'
> >>> vendor/plugins/lbuilder/lib/dryml/template_environment.rb:259:in
> >>> `new_context'
> >>> app/views/test/index.dryml:3:in `render_page'
> >>> vendor/plugins/lbuilder/lib/dryml/template_environment.rb:515:in
> >>> `call'
> >>> ...
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/hobousers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to