[Sdruby] Application Wide Variables

Kevin Clark kevin.clark at gmail.com
Tue Feb 27 22:14:07 GMT 2007


$blah is a global variable.

$blah = "something"

On 2/27/07, Nathan Colgate Clark <nathancolgate at gmail.com> wrote:
> I'm working on making an app a little bit easier to replicate the same
> app for different clients. Does anybody know of a good way to make
> application-wide variables (global variables?).  Right now I'm putting
> this in the bottom of my environments.rb file:
>
> ENV['BUSINESS_NAME'] = "Wilderness Enterprises"
> ENV['BUSINESS_ADDRESS'] = "123 Main"
> etc...
>
> And then using this in the views:
>
> <%= ENV['BUSINESS_NAME']%>
>
> And that doesn't "feel" right... but maybe it is.
>
> -Nathan
> _______________________________________________
> Sdruby mailing list
> Sdruby at lists.sdruby.com
> http://lists.sdruby.com/mailman/listinfo/sdruby
>


-- 
Kevin Clark
http://glu.ttono.us


More information about the Sdruby mailing list