Maybe hardcoding them in a before_filter on ApplicationController... Which kind of variables are you talking about? Where do you plan to use them?
2013/4/14 tamouse mailing lists <[email protected]> > On Sun, Apr 14, 2013 at 6:31 PM, tamouse mailing lists > <[email protected]> wrote: > > On Sun, Apr 14, 2013 at 5:26 PM, Wins Lin <[email protected]> wrote: > >> How to set some variables on bootstap? I need a few variables to be > >> initialized with default values every request. For example in ZF there > >> is a class Bootstrap whose methods are called automatically every > >> request. Is there something similar in Rails? > > > > Do these need to be initialized before configuration? If not, you can > > put them in config/initializers/ > > Never mind, I mis-read what you wrote. > > ZF I'm assuming is Zend Framework, aka, PHP? Which works nothing like > Rails, btw, as you are essentially restarting the entire application > with every request in PHP. > > The Rails application is not brought up and shut down for every > request. It lives in a long running process. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- Ricardo Franco Andrade ( Web | Desktop | Game ) Developer email: [email protected] phone: +55 (86) 9436 0830 linkedin: http://www.linkedin.com/pub/ricardo-franco/61/2b0/857 skype: ricardo.krieg github: https://github.com/ricardokrieg twitter: twitter.com/ricardokrieg facebooK: https://www.facebook.com/krieg.ricardo -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

