是否有可能从移动设备上传通过网络浏览器的图片? [英] Is it possible to upload a picture through a web browser from a mobile device?

查看:200
本文介绍了是否有可能从移动设备上传通过网络浏览器的图片?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这个问题已经被问过,但今年没有 - 没有具体的共识,我知道这是一个热门话题。此外,技术的变化相当快,而其他问题似乎只涉​​及使用<输入类型=文件> 我要寻找一个更详细的现代的方式处理这些请求。虽然我已经在ASP.NET C#MVC3开发,我一直在寻找到天气ASP.NET MVC4手机将支持移动文件上传。从我看过,没有,或者还没有被覆盖在新的发行说明。

This question has been asked before, but not this year - there is no concrete consensus and I know this is a hot topic. In addition, technology changes rather quickly, and the other questions seem to relate to only using the <input type="file>. I am looking for a more verbose modern way to handle these requests. Although I have been developing in ASP.NET C# MVC3, I have been looking into weather ASP.NET MVC4 Mobile will support mobile file upload. From what I have read, it does not, or it has not been covered in the new release notes.

<一个href="http://www.asp.net/vnext/overview/whitepapers/whats-new">http://www.asp.net/vnext/overview/whitepapers/whats-new

<一个href="http://www.asp.net/mvc/tutorials/mvc-4/aspnet-mvc-4-mobile-features">http://www.asp.net/mvc/tutorials/mvc-4/aspnet-mvc-4-mobile-features

从研究,我做的jQuery移动似乎很花哨。

From the research I have done jQuery-Mobile seems rather gimmicky.

<一个href="http://www.parorrey.com/blog/jquery-mobile/file-input-field-uploading-using-jquery-mobile-framework-form-submission-with-ajax-disabled/">http://www.parorrey.com/blog/jquery-mobile/file-input-field-uploading-using-jquery-mobile-framework-form-submission-with-ajax-disabled/

<一个href="http://forum.jquery.com/topic/jquery-mobile-seems-to-clobber-ability-to-upload-files-via-forms">http://forum.jquery.com/topic/jquery-mobile-seems-to-clobber-ability-to-upload-files-via-forms

这是贴在我的iPhone没有工作,一个例子作为&LT;输入类型=文件仍然存在,因此被灰色显示为无法访问

An example that was posted did not work on my iPhone, as the <input type="file" still existed and was therefore grayed out as inaccessible.

<一个href="http://filamentgroup.com/examples/jquery-custom-file-input/">http://filamentgroup.com/examples/jquery-custom-file-input/

另外一个建议,我所遇到的涉及强迫用户通过电子邮件发送照片到用户指定的电子邮件,其中并没有真正吸引我的还是我处理的客户 - 这种做法也似乎像它可能容易受到安全漏洞

Another suggestion I have come across involves forcing the user to email the photo to a user-specific email which doesn't really appeal to me or the customers I deal with - this approach also seems like it could be vulnerable to security breaches.

的有没有办法做到这一点,我已经忽略了?我怎么可以显示在移动设备上的文件对话框?

IS there a way to do this that I have overlooked? How can I show a file dialog on a mobile device?

推荐答案

Safari浏览器不支持文件上传。您可以通过访问众多的移动网站,在实际浏览器,但实际的应用程序将允许此看到这一点。

The Safari browser does not support file uploads. You can see this by visiting many of the mobile sites in the actual browser BUT the actual apps will allow this.

所以,如果你正在你要部署的本机应用程序的移动web应用程序,你可以使用PhoneGap的一个层来做到这一点。

So if you are making a mobile web app that you wish to deploy as a native app, you can use phonegap as a layer to do this.

http://docs.phonegap.com/en/ 1.4.1 / phonegap_file_file.md.html#文件传输

此外,它被支撑在

  • 安卓
  • 在黑莓的WebWorks(OS 5.0或更高版本)
  • 的iOS
  • 的Windows Phone 7(芒果)

这篇关于是否有可能从移动设备上传通过网络浏览器的图片?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆