mirror of
https://github.com/DmcSDK/cordova-plugin-mediaPicker
synced 2026-05-22 00:01:31 +08:00
Update README.md
This commit is contained in:
@@ -35,6 +35,7 @@ index.js code:
|
||||
'maxSelectSize':188743680,//188743680=180M (Optional)
|
||||
};
|
||||
|
||||
|
||||
document.getElementById('openBtn').onclick=function(){
|
||||
MediaPicker.getMedias(args,function(dataArray){
|
||||
//dataArray [{mediaType: "image", path:'/storage/emulated/0/DCIM/Camera/20170808_145202.jpg', path:'/storage/emulated/0/DCIM/Camera/20170808_145202.jpg'}]
|
||||
@@ -42,6 +43,7 @@ index.js code:
|
||||
},err())
|
||||
};
|
||||
|
||||
|
||||
function getThumbnail(dataArray){
|
||||
for(var i=0; i<dataArray.length; i++){
|
||||
//dataArray[i].thumbnailQuality=50; (Optional)
|
||||
@@ -53,6 +55,7 @@ index.js code:
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
document.getElementById('uploadBtn').onclick=function() {
|
||||
//please: cordova plugin add cordova-plugin-file-transfer
|
||||
//see: https://cordova.apache.org/docs/en/latest/reference/cordova-plugin-file-transfer/index.html
|
||||
|
||||
Reference in New Issue
Block a user