Return-Path: X-Original-To: apmail-cordova-issues-archive@minotaur.apache.org Delivered-To: apmail-cordova-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8F3881012B for ; Sat, 29 Nov 2014 15:42:13 +0000 (UTC) Received: (qmail 91212 invoked by uid 500); 29 Nov 2014 15:42:13 -0000 Delivered-To: apmail-cordova-issues-archive@cordova.apache.org Received: (qmail 91144 invoked by uid 500); 29 Nov 2014 15:42:13 -0000 Mailing-List: contact issues-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@cordova.apache.org Received: (qmail 90839 invoked by uid 99); 29 Nov 2014 15:42:13 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 29 Nov 2014 15:42:13 +0000 Date: Sat, 29 Nov 2014 15:42:13 +0000 (UTC) From: "W. Matthew Wilson (JIRA)" To: issues@cordova.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (CB-8103) file method on local file returns mime type "video/3gpp" for .mp4 files MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 W. Matthew Wilson created CB-8103: ------------------------------------- Summary: file method on local file returns mime type "video/3gpp" for .mp4 files Key: CB-8103 URL: https://issues.apache.org/jira/browse/CB-8103 Project: Apache Cordova Issue Type: Bug Components: Android, Plugin File Affects Versions: 3.6.3 Reporter: W. Matthew Wilson I have a feature in my app where a user can pick a video from their gallery and then upload it to a remote server. I need the mime type of the file because right now, I can only process .mp4 files, not .3gp files. I'm using something like this code: window.resolveLocalFileSystemURL( local_video_path, // something like "/media/external/video/media/971" function (f) { console.debug("inside resolveLocalFileSystemURL callback", f); f.file(function (fo) { console.debug("fo", fo); if (fo.size > 30 * 1000 * 1000) { navigator.notification.alert("Sorry, that file is too big! Pick one less than 30 mb."); } else if (fo.type == "video/3gpp") { navigator.notification.alert("Sorry, that file is a .3gp file and we can't handle those!"); } else { // handle file... } }); -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org For additional commands, e-mail: issues-help@cordova.apache.org