RE: Cold Fusion Vs ASP

by "Michael Wilson" <mwilson(at)xionmedia.com>

 Date:  Tue, 30 Oct 2001 14:26:11 -0500
 To:  "'Kathy Wargo'" <kathywargo(at)hotmail.com>,
<hwg-languages(at)hwg.org>
 In-Reply-To:  hotmail
  todo: View Thread, Original
Hi,

Path_translated, a CGI environment variable created by the server, is
the translated version of path_info after any virtual-to-physical
mapping. Keep in mind that some web servers use different CGI
variables... So it might not be available on your server. You _can_ test
to see if the CGI variable is available. ColdFusion will always return
"true" when you test for the existence of a CGI variable. To work around
this, test for an empty string to determine if the CGI variable is
available. Running the following code on my server retruns "CGI variable
exists: Path_translated =
c:\inetpub\wwwroot\961media\Path_translated.cfm".

<html>
<head>
	<title>Does variable exist?</title>
</head>
<body>

<cfif CGI.PATH_TRANSLATED IS NOT "">
  CGI variable exists: Path_translated =
<cfoutput>#CGI.PATH_TRANSLATED#</cfoutput>
<cfelse>
  CGI variable does not exist
</cfif>

</body>
</html>

CGI Environment Variables:

http://hoohoo.ncsa.uiuc.edu/cgi/env.html
http://www.perlfect.com/articles/cgi_env.shtml

Later,

Mike

> -----Original Message-----

> Is there a way that I can establish the pathname similiarly 
> to how I obtain 
> the server path name  similiarly to the path_translated in ASP, thus 
> creating a virtual pathname?

HWG: hwg-languages mailing list archives, maintained by Webmasters @ IWA