Please help me solve this problem. I am a newbie in coldfusion

I want to use a single home page where I'll show a form (that is in another file) to the user to download a file, I also want to show the result of the download on the same page after uploading (result of the action file).

These are my three files:

1 index.cfm

<! - start - >

< html >

< head >

< title > < /title > home page

< cfajaximport tags = "FORM" >

< / head >

< body >

< cfdiv id = 'Hand' style = ' width: 1000px; "height: 600px" >

"< cfdiv id = 'Options' style =" width: 100%; "height: 20%" >

Welcome Admin, < a href = "javascript:ColdFusion.navigate ('FileUpload.cfm', 'Content') ' class = 'settings' > update < /a > < a href =" # "class ="logout"> sign out < /a >"

< / cfdiv >

"< cfdiv id ="Content"style =" width: 100%; height: 80% ">"

< h2 > here will form and FileUploading < / h2 >

< / cfdiv >

< / cfdiv >

< / body >

< / html >

<!-->-->

2.FileUpload.cfm

<! - start - >

< html >

< head >

< title >

Upload a file

< /title >

< / head >

< body >

< cflayout type = "vbox" name = 'layout1' >

< cflayoutarea >

< cfform enctype = "multipart/form-data" action = "FileReceiver.cfm" > "

File to download:

< cfinput type is "file" name is "Filename" size = "50" >

< br / >

< cfinput type = "submit" name = "UploadFile" value = "DOWNLOAD this FILE" >

< br / >

< / cfform >

< / cflayoutarea >

< cflayoutarea >

< table border = "1" >

< b >

< th >

Information about the directory

< /th >

< /tr >

< b >

< td >

< cfoutput >

CurrectDirectory path: #getdirectoryFromPath (expandPath ("index.cfm")) #.

< / cfoutput >

< table >

< /tr >

< /table >

< / cflayoutarea >

< / cflayout >

< / body >

< / html >

<!-->-->

3.FileReceiver.cfm

<!-Start->

< isdefined ('UploadFile') cfif >

< cfoutput >

< cffile nameconflict = "makeunique".

action = "upload".

FileField = "Form.FileName"

destination = "#getdirectoryFromPath (ExpandPath ("index.cfm")) ' # ' > <!-or destination ="c:\Upload\"->"

File upload was successful!

< / cfoutput >

< / cfif >

<!-->-->

When I click the page index "update link" shows the page of FileUpload.cfm in one of its container, but when you download the file

I always get the MESSAGE of ERROR:

Recovery of the cf_layoutarea736558924094373 element markup error: invalid content type: application/x-www-formulaires-urlencoded; Charset = UTF-8. [Enable debugging by adding 'cfdebug' to your URL parameters to see more information]

Help kindly make me right... I am unable to understand the problem...

Ah, I found the cause of the problem: Coldfusion stores the properties of UI such as cfdiv and cflayoutarea tags in the form field. It is what is destroying your upload form. To see this, run the following test code:

Now, looking for a possible solution.

Tags: ColdFusion

Similar Questions

Maybe you are looking for

  • iTunes is misrepresentation ability iPhone

    I have an iPhone running iOS 10.0.0, capacity 6 is 16 GB. According to the phone itself, I 143.5 MB of free storage remaining, but when I try to sync it to iTunes it says that the phone is everywhere from 3.35 to ~ 5 GB more capacity. Part of what ma

  • Build 64-bit DLL

    Hello I'm with LabWindows/CVI 9.0.1 (375) under Windows 7 64 bit and I need to build 64-bit DLL. According to this page http://zone.ni.com/reference/en-XX/help/370051P-01/cvi/programmerref/creating32bitappsversus64bitapp... "" "" I should have a menu

  • How to enable Task Manager in Windows xp home edition?

    I need a step by srep on how to do this. I have a computer with 3 accounts all the account but mine has the task manager disable.

  • new installation activation of Windows 7 pro sp1

    "friends, I have a new installation of windows 7 pro 64 sp 1 who came (oem retail price, newegg) in a sheet of cardboard with the product key in a small gray tag that resembled all intents and purposes be paper that you would remove with the tip of a

  • In the computer management disk management hangs when it is activated

    I'm trying to set a drive letter for one of my external hard drives. The way to do it is to go into the management of the computer, and then select disk management. I can get that far, but when I select disk management it list all my readers, but the