]> granicus.if.org Git - curl/commitdiff
Default Content-Type for formparts has changed to "application/octet-stream".
authorDaniel Stenberg <daniel@haxx.se>
Thu, 13 Nov 2003 07:43:18 +0000 (07:43 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Thu, 13 Nov 2003 07:43:18 +0000 (07:43 +0000)
This seems more appropriate, and I believe mozilla and the likes do this.

.html files now get text/html as Content-Type.

Pointed out in bug report #839806.

lib/formdata.c

index 9ac805bb0012dae09272752256149aea49707dd1..6aaeb167b3d01735ddf88e6f5e4dbdc09dc0ccb8 100644 (file)
@@ -133,7 +133,7 @@ Content-Disposition: form-data; name="FILECONTENT"
 
 /* What kind of Content-Type to use on un-specified files with unrecognized
    extensions. */
-#define HTTPPOST_CONTENTTYPE_DEFAULT "text/plain"
+#define HTTPPOST_CONTENTTYPE_DEFAULT "application/octet-stream"
 
 /* This is a silly duplicate of the function in main.c to enable this source
    to compile stand-alone for better debugging */
@@ -267,7 +267,7 @@ int FormParse(char *input,
            {".jpg",  "image/jpeg"},
            {".jpeg", "image/jpeg"},
            {".txt",  "text/plain"},
-           {".html", "text/plain"}
+           {".html", "text/html"}
          };
 
          if(prevtype)