On Tue, 20 Dec 2005 02:17:47 +0000 (UTC), Mark Stosberg wrote: Hi Mark
I predict great debate on this one :-). > I propose we had add a simple, standard config() method to > CGI::Application. This method will at least get of hashref 'get of' means 'get rid of'? > 2. We have a nice set of Config plugins to choose from, but they > don't agree on even a basic API. This means that new plugins and > extensions can't reliably expect cfg() or config() to exist or or > work a particular way. I understand your motive here, but it's a weak argument. /Every/ module we authors use needs to be used according to its documented interface. So we have to read the docs. It would be a little bit nicer if config-type plugins all had a similar naming convention, but its hardly a driving problem. And won't that lead to conflicts? More below on this. > Applications authors should be encouraged to provide a "root_url" > and "root_dir" as standard config variable names that other > extensions can refer to. Why? Will it return something which uniquely identifies each plugin? And if it does just that, to what use will this value be put? Are you thinking of: $url_1 = Some::Plugin -> root_url(); $url_2 = Some::Other::Plugin -> root_url(): $config_1 = $self -> config($url_1); $config_2 = $self -> config($url_2); in order to manage multiple plugins/configs? > Typically C<config()> is overridden by a plugin which eases the > process the parsing a configuration file. Configuration plugins > that provide at least this basic API include: And what if I use 2 plugins? Do they both override it? I'm confused. -- Ron Savage [EMAIL PROTECTED] http://savage.net.au/index.html --------------------------------------------------------------------- Web Archive: http://www.mail-archive.com/[email protected]/ http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2 To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
