• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

file upload from form using cf8 file functions within cfscript?

New Here ,
May 27, 2008 May 27, 2008

Copy link to clipboard

Copied

essentially, i'm wondering if anyone can give me an example of a way to replicate cffile upload using cf8's native file manipulation functions within a cfscript tag?

more specifically, i am wondering if anyone had any code examples for uploading a file specified by a user on an html form using cf8's file functions (fileOpen, fileCopy, fileDelete, fileMove, fileClose, etc....) within a cfscript tag. i've done this a number of times in the past using upload through cffile, but i'd like to take advantage of cf8's new native file functions and be able to deploy the code within a cfscript block.

i've found some simple examples of the file functions within the docs and online, but nothing showing me how to take a file from an html form and upload it where i want it, as cffile will do.

thanks in advance for any help.
TOPICS
Advanced techniques

Views

407

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 28, 2008 May 28, 2008

Copy link to clipboard

Copied

LATEST
those cf8 file functions are for manipulating files on the server.
you still need to upload the file in one way or another.

as for replicating cffile action=upload in cfscript: just write a
function that uses cffile tag to upload a file, and call that function
from your cfscript!


Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation