Quantcast
Channel: Active questions tagged email - Stack Overflow
Viewing all articles
Browse latest Browse all 29748

Ionic 4 not opening external/default emailing app on IOS device, whilst working on Android

$
0
0

I have written a button to open the phone's default emailing app from my app. It currently works for android and does not work at all for IOS. I am not sure what is wrong and there is not too much information online about this topic. If anyone could guide me, I would be grateful.

Code I have tried and it fails for IOS and works for Android are as follows:

<ion-button expand="block" (click)="emailTest()">
   <ion-label>help@test.co.nz</ion-label>
</ion-button>

emailTest(){
  this._platform.ready().then(() => {
      window.open('mailto:help@test.co.nz');
  });
}
<ion-button expand="block">
   <a href="help@test.co.nz" style="color:white">help@test.co.nz</a>
</ion-button>
<ion-button expand="block" (click)="emailTest()">
   <ion-label>help@test.co.nz</ion-label>
</ion-button>

emailTest(){
  window.open("mailto: help@test.co.nz",'_system');
}

Viewing all articles
Browse latest Browse all 29748

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>