2016-08-24 20 views
2

Ionic Frameworkでアプリを構築しています。ここで画像をフィードに投稿し、ソーシャルメディアに共有できます。私はCordovaプラグインのSocialSharingを使用します。 Androidでは、WhatsAppに画像を共有するとうまく動作します。 iPhoneでは、テキストはイメージと共有されますが、イメージは共有されません。 Facebookなどへの共有は、両方のデバイスでうまくいきます。WhatsAppへのIOS画像の共有が機能しない

iPhoneのWhatsAppで動作しない理由は何ですか?

これはcontrollers.jsでのコードです:

$scope.shareImage = function (item) { 
    $cordovaSocialSharing 
     .share(item.note.text, null, item.image, null) 
     .then(function (result) { 
     }, function (err) { 
      console.log(err); 
     }); 
}; 

とビューでのHTML:

<div class="share-image" ng-click="shareImage(item)"> 
    Share this picture 
</div> 

答えて

0

私はそれを修正(私のプロジェクトの一つにこのコードの平和を使用)あなたと同じ変数を使用します

あなたのビュー

<div class="share-image" ng-click="shareImage(item)"> 
    Share this picture 
</div> 

コントローラ

$scope.shareImage = function(item){ 
    window.plugins.socialsharing.share(null, null, 'item.image', null)" 
}; 
関連する問題