我可以使用 Titanium Appcelerator 通过 Android 的照片库将照片上传到服务器吗?

发布于 2024-11-03 14:35:30 字数 91 浏览 0 评论 0原文

我在 Appcelerator 论坛上问过这个问题,但没有回复。我也尝试过用照片库上传照片但失败了。 Titanium 支持在 Android 中通过照片库上传照片吗?

I have asked this question on Appcelerator forum but no reply. I have also tried to upload photo with photo gallery but failed. Is uploading photo through photo gallery in Android supported by Titanium?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

谁对谁错谁最难过 2024-11-10 14:35:30

我找不到有关该主题的任何真正的官方文档,但据此。 https://github.com/appcelerator/KitchenSink/blob/master /Resources/examples/camera.js

var data = [
    {title:'Camera Basic', hasChild:true, test:'../examples/camera_basic.js'}
];

if (Ti.Platform.osname == "iphone") {
    data.push({title:'Camera Custom Overlay', hasChild:true, test:'../examples/camera_overlay.js'});
    data.push({title:'Camera Overlay Webview', hasChild:true, test:'../examples/camera_overlay_webview.js'});
    data.push({title:'Camera Augmented Reality', hasChild:true, test:'../examples/camera_ar.js'});
    data.push({title:'Save to Gallery (Auto)', hasChild:true, test:'../examples/camera_gallery.js'});
    data.push({title:'Save to File', hasChild:true, test:'../examples/camera_file.js'});    

    Ti.include('version.js');

    if (isiOS4Plus()) {
        data.push({title:'Video Record', hasChild:true, test:'../examples/camera_video.js'});   

        //TODO: this seems to work the first time, but not subsequent. fix for 1.5
        //data.push({title:'Video Editing', hasChild:true, test:'../examples/video_edit.js'});  
    }
}

似乎所有工作相机功能(包括保存到文件)都设置为 iphone

但是您是否已阅读此页面并尝试过此 https://github.com/appcelerator/KitchenSink/blob/master/Resources/examples /xhr_fileupload.js

I can't find any real official documentation on the subject but according to this. https://github.com/appcelerator/KitchenSink/blob/master/Resources/examples/camera.js

var data = [
    {title:'Camera Basic', hasChild:true, test:'../examples/camera_basic.js'}
];

if (Ti.Platform.osname == "iphone") {
    data.push({title:'Camera Custom Overlay', hasChild:true, test:'../examples/camera_overlay.js'});
    data.push({title:'Camera Overlay Webview', hasChild:true, test:'../examples/camera_overlay_webview.js'});
    data.push({title:'Camera Augmented Reality', hasChild:true, test:'../examples/camera_ar.js'});
    data.push({title:'Save to Gallery (Auto)', hasChild:true, test:'../examples/camera_gallery.js'});
    data.push({title:'Save to File', hasChild:true, test:'../examples/camera_file.js'});    

    Ti.include('version.js');

    if (isiOS4Plus()) {
        data.push({title:'Video Record', hasChild:true, test:'../examples/camera_video.js'});   

        //TODO: this seems to work the first time, but not subsequent. fix for 1.5
        //data.push({title:'Video Editing', hasChild:true, test:'../examples/video_edit.js'});  
    }
}

It seems that all working Camera functions including the save to file is set to iphone

However have you read up on this page and tried this https://github.com/appcelerator/KitchenSink/blob/master/Resources/examples/xhr_fileupload.js

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文