my.saveImage

Save the online images to a device camera gallery.

Sample Code

copy
my.saveImage({url:'https://img.example.com/example.jpg'});

Parameters

PropertyType

Required

Description
urlStringYesURL of the image to be saved.
showActionSheetBooleanNo

Whether to show the menu when saving image, by default it is true.

successFunctionNoCallback function upon call success.
failFunctionNoCallback function upon call failure.
completeFunctionNoCallback function upon call completion (to be executed upon either call success or failure).

Error Code

ErrorDescription
2Invalid parameter, no url parameter   transferred.
15Album right not enabled (iOS only).
16Insufficient album storage on   cellphone (iOS only).
17Other errors during picture saving.