Hi Hugo,

You could try using java.lang.System.getenv().

  <cfdump var=#createObject( "java", "java.lang.System" ).getenv()#>

Andy

Hugo Ahlenius wrote:
> Hi,
>
> I am playing with an application that I have moved from Bluedragon.Net -
> there I did a little check to get the name of the serving computer - and I
> would like to move that to OpenBD somehow... I would prefer to have this set
> server-wide at some place outside the application.
>
> On BD.Net I had this set in the global config file - machine.config - that
> covers the whole .Net environment, and I accessed this like:
>
> <cfset Sys =
> CreateObject("java","System.Configuration.ConfigurationSettings") />
> <cfset thisMachine = Sys.get_AppSettings().Get("thismachine") />
>
> An alternate way was to do:
> <cfset thisMachine =
> CreateObject("java","System.Environment").get_MachineName() />
>
> How would one go about for this on OpenBD? Getting a OS environment variable
> (e.g. %COMPUTERNAME% on Windows) would be ok to - one can always do this
> with cfexecute...
>
> I guess that the analogous thing to the .net-way would be to define it in a
> CGI variable (in the web server) or in the appserver config (I am on tomcat
> - e.g. web/server.xml)
>
> Related - I tried setting a CGI/Request variable in Apache ("SetEnv") - but
> that didn't seem to have propagated when I did a <cfdump> of the cgi
> scope...
>
> The server is Win2k3, and my dev machine is running Vista urtimate, with
> Tomcat and Apache.
>
> Cheers,
> H.
>
> --
> Hugo Ahlenius
> fraxinus (at-sign) oxel.net
> http://www.oxel.net 
>
>
>
>
>
>
> >
>   


--~--~---------~--~----~------------~-------~--~----~
Open BlueDragon Public Mailing List
 http://groups.google.com/group/openbd?hl=en
 official site @ http://www.openbluedragon.org/

!! save a network - trim replies before posting !!
-~----------~----~----~----~------~----~------~--~---

Reply via email to