如何通过使用phonegap上传mp3文件到服务器(xxampp)。 [英] how can upload mp3 file to the server(xxampp) by using phonegap.?

查看:112
本文介绍了如何通过使用phonegap上传mp3文件到服务器(xxampp)。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请建议我如何使用 phonegap 将音频文件上传到服务器。

Please suggest me how can upload audio file to the server by using phonegap.?

我想创建一个文件浏览选项用户提供要上传的

文件的位置。

I want to make a file browse option by which user provide the location of file which
is to be uploaded.

按下提交按钮文件后应保存在服务器端的mysql数据库。
i am使用php服务器端存储数据。

After pressing submit button file should be save in mysql data base on server side. i am using php for server side storing data.

您可以提供链接,这可能有助于获得一些与这个
工作相关的知识。

You can provide me links which may be helpful to get some knowledge related to this work.

推荐答案

您可以从PhoneGap将文件发送到您的服务器,下面是一个非常实例的api:

You can POST a file to your server from PhoneGap, here's the api with a pretty solid example:

http://docs.phonegap.com/phonegap_file_file .md.html#FileTransfer

然后,您可以使用PHP(或其他任何东西)来获取该POST并执行任何您想要的操作,将数据保存为sql ,写入文件等。

Then you can use PHP (or anything else) to pick up that POST and do whatever you want, save data as sql, write files, etc.

这篇关于如何通过使用phonegap上传mp3文件到服务器(xxampp)。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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