Skip to content
Browse files

Enabled the FormData support for WebKit since it works pretty good.

  • Loading branch information...
1 parent 5aa18d1 commit dec48ff5d22b549c9da6280b9a6528f0615cecc1 @spocke spocke committed Aug 16, 2010
Showing with 4 additions and 4 deletions.
  1. +1 −1 changelog.txt
  2. +2 −2 examples/upload.php
  3. +1 −1 src/javascript/plupload.html5.js
View
2 changelog.txt
@@ -2,7 +2,7 @@ Version 1.2.x (2010-xx-xx)
Added new BeforeUpload event to make it easier to override settings before a file is uploaded.
Added new automatic usage of FileReference in Flash if it's possible. Contributed by Marcel Jackwerth.
Added new chunking support for Chrome 5 and Firefox 3.6 using the HTML 5 runtime.
- Added new multipart upload support for Chrome 6 using the HTML 5 runtime.
+ Added new multipart upload support for WebKit using the HTML 5 runtime and the FormData object.
Added new image scaling method for the Flash runtime contributed by rcoopman.
Added new alert error message if the user selected invalid files.
Added new automatic unique name generation to the example.php script. Contributed by Brandon Kelly.
View
4 examples/upload.php
@@ -35,13 +35,13 @@
$fileName = preg_replace('/[^\w\._]+/', '', $fileName);
// Make sure the fileName is unique
- if (file_exists($path . DIRECTORY_SEPARATOR . $fileName)) {
+ if (file_exists($targetDir . DIRECTORY_SEPARATOR . $fileName)) {
$ext = strrpos($fileName, '.');
$fileName_a = substr($fileName, 0, $ext);
$fileName_b = substr($fileName, $ext);
$count = 1;
- while (file_exists($path . DIRECTORY_SEPARATOR . $fileName_a . '_' . $count . $fileName_b))
+ while (file_exists($targetDir . DIRECTORY_SEPARATOR . $fileName_a . '_' . $count . $fileName_b))
$count++;
$fileName = $fileName_a . '_' . $count . $fileName_b;
View
2 src/javascript/plupload.html5.js
@@ -90,7 +90,7 @@
dragdrop: window.mozInnerScreenX !== undefined || sliceSupport,
jpgresize: dataAccessSupport,
pngresize: dataAccessSupport,
- multipart: dataAccessSupport || !!window.FileReader,
+ multipart: dataAccessSupport || !!window.FileReader || !!window.FormData,
progress: hasProgress,
chunking: sliceSupport || dataAccessSupport
};

0 comments on commit dec48ff

Please sign in to comment.
Something went wrong with that request. Please try again.