FYI

I've sort it! I've sniffed the traffic between the browser and
Jetty/Cocoon with Ethereal and discovered that the .csv file is sent
with mime-type "application/vnd.ms-excel"?! Perhaps this happens only
when the file is uploaded from a Windows machine, so just in case I
changed the mime-types as:

    <fd:upload id="file_contratosnovos" mime-types="text/csv,
    application/vnd.ms-excel" required="true">

Hope this can help others!

On Fri, 01 Jul 2005 19:25:14 +0100, "Carlos Gama" <[EMAIL PROTECTED]>
said:
> Hi all,
>   I'm tryed to change the upload sample/demo that comes with cocoon
>   2.1.7 to allow the upload of .csv files instead of "simple" text files
>   (i.e. .txt) but I allways get the "upload.invalid-type" (i.e. "Invalid
>   Content Type") validation error when I submmit the form!?
> 
> All I did was changing the the mime-types attribute in the sample's form
> model (upload_model.xml), from "text/plain" to "text/csv":
> 
>     <fd:upload id="upload" mime-types="text/csv" required="true">
> 
> I've also tried "text/x-csv", with no joy!
> 
> Can someone help me with this?
> 
> I'm using Cocoon 2.1.7, with the bundled Jetty server. JDK is Sun 1.5.3.
> OS is Win XP Pro SP2. And the browser I'm using is Firefox 1.0.4.
> 
> Any hints about how to upload a .csv file would be much appreciated.
> 
> Thanks in advance,
> Carlos Gama
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to