cool, thanks!

Dave

----- Original Message -----
From: <"Owens>; <Howard <[EMAIL PROTECTED]>>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Friday, February 14, 2003 3:49 PM
Subject: RE: a different cffile upload ?


> Because my hosting environment is a cluster, I need to use a UNC path,
while
> my local environment is just one machine. So for me, the
> GetDirectoryFromPath() method doesn't work.
>
> Here's what I do -- on the Application.cfm page:
>
> <cfswitch expression="#CGI.SERVER_NAME#">
>
> <cfcase value="localhost">
> <cfscript>
> //set DSN variable
> request.GLDSN='localDSN';
>
> request.siteurl='http://localhost/mysite/';
> request.securesiteurl='http://localhost/mysite/';
> request.pictureupload='c:\inetpub\wwwroot\mysite';
> request.filewrite='c:\inetpub\wwwroot\mysite\';
>
> //linkpath, below, is generally a cold fusion mapping set up
> in the administrator
> request.cfmapping='/sitemapping/';
>
> </cfscript>
>
>
> </cfcase>
>
>
> <cfcase value="www.livedomain.com">
> <cfscript>
> //set DSN variable
> request.GLDSN='liveDSN';
>
> request.siteurl='http://www.livedomain.com/';
> request.securesiteurl='https://www.livedomain.com/';
> request.pictureupload='\\inetpub\wwwroot\mysite';
> request.filewrite='\\\inetpub\wwwroot\mysite\';
>
> //linkpath, below, is generally a cold fusion mapping set up
> in the administrator
> request.cfmapping='/sitemapping/';
>
> </cfscript>
>
>
> </cfcase>
>
> </cfswitch>
>
> With this system, I don't have to keep switching things around depending
on
> what server I'm using (I actually set the Application.cfm page for about
> four different server environments I might us for devleopment, production
> and deployment).
>
> Maybe this will help you.
>
> H.
>
>
> > -----Original Message-----
> > From: Ben Doom [SMTP:[EMAIL PROTECTED]]
> > Sent: Friday, February 14, 2003 12:26 PM
> > To: CF-Talk
> > Subject: RE: a different cffile upload ?
> >
> > I believe that destination is a local filesystem path, so something like
> > c:\inetpub\wwwroot\sitename\subdir\filename.jpg
> >
> > If you need to find that location dynamically, you can use something
like
> > GetDirectoryFromPath(GetCurrentTemplatePath()) to get the absolute local
> > filesystem path to the calling template.
> >
> > HTH.
> >
> >
> > --  Ben Doom
> >     Programmer & General Lackey
> >     Moonbow Software, Inc
> >
> > : -----Original Message-----
> > : From: Dave Lyons [mailto:[EMAIL PROTECTED]]
> > : Sent: Friday, February 14, 2003 3:22 PM
> > : To: CF-Talk
> > : Subject: a different cffile upload ?
> > :
> > :
> > : trying to simply the transition between development comp and
> > : server, can I use this:
> > :
> > : <cffile
> > : action="upload"
> > : filefield="imagefile"
> > : destination="http://#CGI_Server_Name#/uploads/filename.jpg";
> > : nameConflict="overwrite">
> > :
> > :
> > : or do i have to specify the destination specifically like so:
> > :
> > : <cffile
> > : action="upload"
> > : filefield="imagefile"
> > : destination="path/filename.jpg"
> > : nameConflict="overwrite">
> > :
> > :
> > : dave
> > : <!--- doesnt know jack about cfm --->
> > :
> > :
> > :
> >
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to