How to send attachments (images) and nested params using XHR to uplaoad file in titanium?
问题 I am trying to upload images from the photo gallery of the phone to the server. Images gallery is opening perfectly fine. Here is my code. var win = Ti.UI.createWindow({ navBarHidden : true, }); var ind = Titanium.UI.createProgressBar({ width : 200, height : 50, min : 0, max : 1, value : 0, style : Titanium.UI.iPhone.ProgressBarStyle.PLAIN, top : 10, message : 'Uploading Image', font : { fontSize : 12, fontWeight : 'bold' }, color : '#888' }); win.add(ind); ind.show(); var main_url = "http:/