ok rereading u say it works on dev but not live, are u sure u have the correct 
live path? its different then your dev path

ok did u rename your Application.cfm page?
also when they say to set the folder permissions you do that with your ftp 
client not your cfm code

also, the path to upload will be different on your dev machine and on the live 
server be sure to get them right, ASK YOUR HOST FOR THE CORRECT PATH, using 
what i have included wont work, u need to get this from the host

this is assuming u have 2 fileds in your form, name & picture1 and of course 
picture1 is a file field


Application.cfm page
------------------dont include this line-------------------------------


<!--- set global variables --->
<cfset HOMEPAGE="http://www.yoursite.com/";>
<cfset upload="/vservers/yoursite/htdocs/uploads/">



PROCESS PAGE
------------------dont include this line-------------------------------



<!--- make sure form was submitted --->
<cfif NOT isdefined("form.submit")>
        <h2>Sorry there has been an error, please try again</h2>
        <p><a href="javascript:history.go(-1);">Go back</a></p>
        <cfabort>
</cfif>


<!--- do the file 1 upload now --->
<cfif #form.picture1# NEQ "">
        <cffile Action="upload" 
        filefield="picture1" 
        destination="#upload#" 
        nameconflict="makeunique" 
        accept="image/*">
        <cfset picture1 = #file.serverfile#>
</cfif>



<!--- set form variables --->
<cfset name = #trim(form.name)#>


<!--- do insert now --->
<cfquery name="qNL" datasource="#DSN#" username="#un#" password="#pw#">
        INSERT INTO user (name, picture1)
        VALUES (
                <cfqueryparam value="#name#" cfsqltype="cf_sql_varchar">
                ,
                <cfqueryparam value="#picture1#" cfsqltype="cf_sql_varchar">
                )
</cfquery> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Special thanks to the CF Community Suite Gold Sponsor - CFHosting.net
http://www.cfhosting.net

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:184180
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to