Hi guys,
I´m trying to change a SMTP method on my rails application creating a
file on initializers folder, but I'm getting this error: uninitialized
constant Net (NameError)
I don't know if I'm doing this right, here it's my .rb file I put on
initializers folder.
initializers/test.rb
Net::SMTP.
I restarted the server and it appears to have worked.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from
Hey all,
In app/builders, I have a file called table_builder.rb. In the
constructor method of my TableBuilder class, I call an instance method
called assign_attributes which takes a hash and converts the key/value
pairs into instance methods.
The assign_attributes method is declared in the follow
I am upgrading an app from Rails 2.3.8 to Rails 3.0. I am finding that
the initializers in the initializers directory do not seem to load. Is
there any way to configure it. In general, what are the new load
procedures for Rails 3?
Thanks.
Bharat
--
Posted via http://www.ruby-forum.com/.
--
Yo
Have a bit of a conundrum that I need to solve
I would like to put this into environment.rb...
config.action_mailer.default_url_options = { :host =>
Setting[:website_url] }
but it obviously can't read from the database before it is initialized
and the configuration for action_mailer 'options' ap
I created a "config/initializers/tasks.rb"
In it I have the following is all:
logger.info("Running tasks")
However nothing is logged or run. Am I missing something?
--
Posted via http://www.ruby-forum.com/.
--~--~-~--~~~---~--~~
You received this message becaus
I want to decorate ActiveRecord with a new method so that any classes
that inherit from it also have the method.
I've been told that initializers are the way to go, yet when I put a
file in initializers containing:
class << ActiveRecord::Base
def methodName(params)
end
end
The method do
Hi all,
I have a file in config/initializers that specifies plan types. The
file is:
==
APP_PLANS = [
{
"id" => 0,
"name" => 'free',
"Price" => 0,
"Users" => 1,
"Storage"=> 0,
"SSL"=> true
}, {
"id"
Hello,
My project have strange behavior diferent than I expected.
If I place a line like below after the Rails::Initializer block from
my enviroment file it will work fine:
PROJECT_NAME = I18n.t("settings.name")
But If I move this to a initializer file it will get the translation
error:
"tran
9 matches
Mail list logo