search for: app_config

Displaying 14 results from an estimated 14 matches for "app_config".

2011 Apr 21
1
Rails 3 Foreign Domain routing - cannot get this to work!
...#39;m attempting to build an app based on this example: http://glacialis.postmodo.com/ so, as in this example, I''ve created lib/personalized_domain.rb [code] # lib/personalized_domain.rb class PersonalizedDomain def self.matches?(request) case request.host when ''www.#{APP_CONFIG[:domain]}'', ''#{APP_CONFIG[:domain]}'', nil false else true end end end [/code] and in my routes I have this: [code] # config/routes constraints(PersonalizedDomain) do namespace :personalized, :path => ''/'' do root :to =&gt...
2008 Jan 31
1
RSpec and the Basecamp API
...that this is kind of a basic question but I''m new to rspec and still trying to work out how to do things. I''m working on a rails project that requires basecamp integration via the api, which is fairly trivial to use via the basecamp.rb wrapper: Connection: basecamp = Basecamp.new(APP_CONFIG[''api_host''], APP_CONFIG[''api_username''], APP_CONFIG[''api_pwd'']) And to retrieve a list of Projects: puts "Projects: #{basecamp.projects}" I know how to make this work in the model, I''m just having trouble working out how to...
2007 Aug 07
0
Edge Rails and ActionMailer problem (Bad file descriptor)
...r whenever I attempt to send an email using action mailer, I gain the following error, any suggestions t whats going wrong? Bad file descriptor - connect(2) I am using the following settings ActionMailer::Base.delivery_method = :smtp ActionMailer::Base.smtp_settings = { :address => APP_CONFIG[''smtp''][''address''], :port => APP_CONFIG[''smtp''][''port''], :domain => APP_CONFIG[''smtp''][''domain''], :user_name => APP_CONFIG[''smtp''...
2009 Mar 25
1
I18n + ActionMailer = conflict ?
...ssage: "undefined method ''t'' for #<Mailer:0xb6d501e0>" ... when I call the following Mailer? ================================= class Mailer < ActionMailer::Base def signup_notification(user) @recipients = "#{user.email}" @from = APP_CONFIG[''mail''][''sender''] @subject = "#{APP_CONFIG[''settings''][''name'']} - " @subject += "#{ t(''.activate_new_account'') }." @body[:user] = user @body[:url] = "http://#...
2010 Sep 07
0
numeric key in yam file to be used by config file
I am using a YAML file for my app config, loading it : ---- raw_config = File.read(RAILS_ROOT + "/config/app_config.yml") APP_CONFIG = YAML.load(raw_config)[RAILS_ENV].symbolize_keys --- It''s running well as long as I use alpha keys development: seve: api_token: e09cba8653489749388797926512bb75 then APP_CONFIG[:seve]["api_token"] gives me e09cba8653489749388797926512bb75 BUT...
2008 Apr 15
2
environment.rb uninitialized constant when starting console
I have the following code in environment.rb: require File.join(File.dirname(__FILE__), ''boot'') raw_config = File.read(RAILS_ROOT + "/config/config.yml") APP_CONFIG = YAML.load(raw_config)[RAILS_ENV] This works fine when running the server, but if I try and start a console I get: Loading development environment. ./script/../config/../config/environment.rb:15:NameError: uninitialized constant YAML Can anyone help me out? Thanks. Chris --~--~---------~--~--...
2011 Apr 27
3
Can't configure cach_store in an initializer
I''m trying to use redis-store as my cache_store. I also have an app_confirg.rb initalizer which loads a yaml file for config settings. In my redis.rb initializer I have: MyApp::Application.config.cache_store = :redis_store, APP_CONFIG[''redis''] However, this doesn''t appear to work. If I do Rails.cache in my rails console I can clearly see it''s using the ActiveSupport.Cache.FileStore as the cache store instead of redis. However, if I add the config in my application.rb file it works just fine,...
2008 Sep 02
3
Unable to set default_url_options[:host] for Action Mailer
I am attempting to provide ActionMailer with the request host needed to generate a url. Here is my code: In config/environments/development.rb config.action_mailer.default_url_options = { :host => "development_url.com" } and in config/environments/production.rb config.action_mailer.default_url_options = { :host => "production_url.com" } When I run the above code
2007 Oct 26
3
Selecting a database from the application itself?
Hi everybody, I just started thinking about a project and am seeking some help regarding its design. The idea would be to create labels (i.e. address labels).I could let users type the text manually, but I dont think they would appreciate that when they''ll want to print 5000 addresses. I can also probably let them import csv files, that should not be a problem, but playing with those
2006 Dec 11
0
auth_generator 2.0.1 undefined method `login_required' for ... ArticlesController
...ew Help would be appreciated. My app/controllers/application.rb reads... ------------------------------------------------------------------------ require ''auth_system'' class ApplicationController < ActionController::Base include AuthSystem helper :auth before_filter :app_config, :ident service :notification # Used to be able to leave out the action def process(request, response) catch(:abort) do super(request, response) end response end def this_auth @app end helper_method :this_auth end ----------------------------------------------...
2009 Apr 09
4
uninitialized constant ActionView::Helpers::AssetTagHelper
Hi All, I just wiped out my hard drive, did a fresh install of os x 10.5, and upgraded to rails 2.3.2. i installed the mysql pkg for os x, and created the databases i needed for the project i was working on before the upgrade. However when i run rake db:migrate to run my migrations i get this error uninitialized constant ActionView::Helpers::AssetTagHelper I''ve found some stuff about
2009 Nov 04
11
Sending Mails with mutations ä,ü,ö
Hi everyone I am sending mails with rails in German. The Problem is that the German letters ä,ü,ö are arriving correctly at the receiver. When the subject contains the word Für the receiver gets Für Does anybody knows this issue? Thanks in advance. Adam -- Posted via http://www.ruby-forum.com/.
2006 Jan 09
7
File_column Dynamic directory
I asked this question earlier and did recieve an answer but I am not sure Ifully understood the answer as I am getting all sorts of errors when trying to implement. Basically I want to add a layer to the path for my files. I have the following set up in my model class: file_column :image, :store_dir => :dynamic_dir def dynamic_dir
2012 Nov 09
0
Wine release 1.5.17
...ion. jscript: Added more enumerable attribute tests. mshtml: Don't call CP event sinks on detached documents. mshtml: Keep reference to document node in fire_event_obj. mshtml: Ignore one more property change notification to fix some IE installations. widl: Ignore -app_config option. mshtml: Added IHTMLObjectElement::name property implementation. mshtml: Don't pass hash part of URI to EvaluateNewWindow. mshtml: Call set_current_uri in navigate_proc. mshtml: Use fregment-less URI in super_navigate. mshtml: Added IPersistHistory::SaveHist...