Thanks Charlie. That will do me :)
Ben
Charlie Garrison wrote:
Good morning,
On 15/04/09 at 1:24 PM +0100, Ben Vinnerd <[email protected]>
wrote:
I pass a flag to Apache when i start it up, e.g. -Dhello. Any ideas
how i can check this from within a Catalyst app?
If using mod_perl, then inside your IfDefine block, do a PerlSetEnv
(or maybe a PerlSetVar), eg:
PerlSetEnv SERVER_MODE "test"
And then just check for key %ENV to see if the -D flag was applicable
for that request.
The same technique should work with fast_cgi but you'll need to use
SetEnv rather than PerlSetEnv (unless fast_cgi has PerlSetEnv
equivalent).
Charlie
_______________________________________________
List: [email protected]
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/