Forum: Ruby on Rails App Configuration Setting

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
DAZ (Guest)
on 2009-01-15 15:55
(Received via mailing list)
What is the best way to allow site-wide setting to be changed?

For example, an admin user could be able to set the site theme, the
number of images shown on the landing page, the title of the app,
greeting given etc.

Solutions I can think of are:
Database Solution
----------------------------
A Site model, with only one instance

File Based Solution
--------------------------------
Configuration file(s) that can be edited by admins from within the
browser


What do people think or do in their sites?

cheers,

DAZ
Philip H. (Guest)
on 2009-01-15 18:25
(Received via mailing list)
On Jan 15, 2009, at 5:54 AM, DAZ wrote:

> A Site model, with only one instance
>
> File Based Solution
> --------------------------------
> Configuration file(s) that can be edited by admins from within the
> browser
>
>
> What do people think or do in their sites?

I use http://agilewebdevelopment.com/plugins/application_config for
things that won't change frequently... api keys, etc...

Other times I've created a Preference model with key/value attributes
and they can edit that...

-philip
This topic is locked and can not be replied to.